diff options
Diffstat (limited to 'runtime/transport')
-rw-r--r-- | runtime/transport/ChangeLog | 6 | ||||
-rw-r--r-- | runtime/transport/symbols.c | 19 |
2 files changed, 15 insertions, 10 deletions
diff --git a/runtime/transport/ChangeLog b/runtime/transport/ChangeLog index 42c6fc2a..02f73992 100644 --- a/runtime/transport/ChangeLog +++ b/runtime/transport/ChangeLog @@ -1,3 +1,9 @@ +2008-10-07 Frank Ch. Eigler <fche@elastic.org> + + PR 4886 + * symbols.c (_stp_do_relocation): Simplify processing of build-id + note address. + 2008-09-17 Frank Ch. Eigler <fche@elastic.org> PR 6487, 6504. diff --git a/runtime/transport/symbols.c b/runtime/transport/symbols.c index faba0986..1cd78724 100644 --- a/runtime/transport/symbols.c +++ b/runtime/transport/symbols.c @@ -51,20 +51,19 @@ static void _stp_do_relocation(const char __user *buf, size_t count) if (strcmp (_stp_modules[mi]->name, msg.module)) continue; - /* update note section to represent loaded */ - if (_stp_modules[mi]->notes_sect == 0) - _stp_modules[mi]->notes_sect = 1; + if (!strcmp (".note.gnu.build-id", msg.reloc)) { + _stp_modules[mi]->notes_sect = msg.address; /* cache this particular address */ + } + for (si=0; si<_stp_modules[mi]->num_sections; si++) { - if (!strcmp (".note.gnu.build-id", msg.reloc)) { - _stp_modules[mi]->notes_sect = msg.address; - continue; - } - if (strcmp (_stp_modules[mi]->sections[si].name, msg.reloc)) continue; - - _stp_modules[mi]->sections[si].addr = msg.address; + else + { + _stp_modules[mi]->sections[si].addr = msg.address; + break; + } } /* loop over sections */ } /* loop over modules */ } |