diff options
Diffstat (limited to 'libelf/libelf_ar_util.c')
| -rw-r--r-- | libelf/libelf_ar_util.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libelf/libelf_ar_util.c b/libelf/libelf_ar_util.c index 7e6ec4068f69..7b824fb579a9 100644 --- a/libelf/libelf_ar_util.c +++ b/libelf/libelf_ar_util.c @@ -34,7 +34,7 @@ #include "_libelf.h" #include "_libelf_ar.h" -ELFTC_VCSID("$Id: libelf_ar_util.c 3013 2014-03-23 06:16:59Z jkoshy $"); +ELFTC_VCSID("$Id: libelf_ar_util.c 3157 2015-02-15 21:42:02Z emaste $"); /* * Convert a string bounded by `start' and `start+sz' (exclusive) to a @@ -278,8 +278,8 @@ _libelf_ar_open(Elf *e, int reporterror) * Handle special archive members for the SVR4 format. */ if (arh.ar_name[0] == '/') { - - assert(sz > 0); + if (sz == 0) + goto error; e->e_flags |= LIBELF_F_AR_VARIANT_SVR4; |
