diff options
author | Mark Wielaard <mjw@redhat.com> | 2015-05-12 15:59:04 +0200 |
---|---|---|
committer | Mark Wielaard <mjw@redhat.com> | 2015-05-18 15:48:04 +0200 |
commit | 6d93c8c46d9b2b381c889e5f176451996845b055 (patch) | |
tree | 7ed9e6ec8c9cfa1a2b49936b87c87cb4b9ce4717 /src/ChangeLog | |
parent | c0748eff8473b0caa6d51812aa31349bf1dce042 (diff) | |
download | android_external_elfutils-6d93c8c46d9b2b381c889e5f176451996845b055.tar.gz android_external_elfutils-6d93c8c46d9b2b381c889e5f176451996845b055.tar.bz2 android_external_elfutils-6d93c8c46d9b2b381c889e5f176451996845b055.zip |
strip: Harden against bogus input files. Don't leak tmp debug file on error.
There were various places where a bogus/unexpected input file would cause
eu-strip to crash. Also on an unexpected error eu-strip would leak the temp
debug file it was writing.
https://bugzilla.redhat.com/show_bug.cgi?id=1170810#c34
Signed-off-by: Mark Wielaard <mjw@redhat.com>
Diffstat (limited to 'src/ChangeLog')
-rw-r--r-- | src/ChangeLog | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 55bd4ccf..02f65842 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,16 @@ +2015-05-12 Mark Wielaard <mjw@redhat.com> + + * strip.c (debug_fd): New static variable. + (tmp_debug_fname): Likewise. + (cleanup_debug): New function using the above to clean up temporary + debug file. + (INTERNAL_ERROR): Call cleanup_debug. + (handle_elf): Use debug_fd and tmp_debug_fname statics and call + cleanup_debug before any error. Use output_fname instead of fname in + error messages when it exists (-o was given). SHT_NOBITS sections + can also be moved freely even if SHF_ALLOC is set. Add various + sanity checks. Use elf_assert instead of plain assert. + 2015-05-08 Mark Wielaard <mjw@redhat.com> * nm.c (show_symbols): Call gelf_fsize with EV_CURRENT. |