aboutsummaryrefslogtreecommitdiff
path: root/src/libmach
diff options
context:
space:
mode:
authorDavid du Colombier <0intro@gmail.com>2017-09-01 22:37:05 +0200
committerDavid du Colombier <0intro@gmail.com>2017-09-01 22:37:05 +0200
commitcf303e5baa13e9c35acb8531260a67d11e5051ab (patch)
tree02144aeaa269792b5b9d447b13d414f086c0226a /src/libmach
parent2f9bf88b364fe9311005da39fdbd0692ddd9998e (diff)
downloadplan9port-cf303e5baa13e9c35acb8531260a67d11e5051ab.tar.gz
plan9port-cf303e5baa13e9c35acb8531260a67d11e5051ab.tar.bz2
plan9port-cf303e5baa13e9c35acb8531260a67d11e5051ab.zip
libmach: initialize ss variable in stabsline2pc function
Fixes #58.
Diffstat (limited to 'src/libmach')
-rw-r--r--src/libmach/symstabs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libmach/symstabs.c b/src/libmach/symstabs.c
index 77c6bab7..e253f023 100644
--- a/src/libmach/symstabs.c
+++ b/src/libmach/symstabs.c
@@ -309,7 +309,8 @@ stabsline2pc(Fhdr *fhdr, u64int startpc, ulong line, u64int *pc)
l.type = LADDR;
l.addr = startpc;
- if((s = ffindsym(fhdr, l, CTEXT)) == nil)
+ if((s = ffindsym(fhdr, l, CTEXT)) == nil
+ || stabsym(&fhdr->stabs, s->u.stabs.i, &ss) < 0)
return -1;
trigger = 0;