summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2024-01-26 00:19:01 +0000
committermidipix <writeonce@midipix.org>2024-01-26 00:19:01 +0000
commit8a08048c6b3d4258b9d6ee206c22eb48b3d304fe (patch)
treee50d548543d926f235bb9e61485c1fa34f63a549
parent3fcae4969c8767d0e3da21b8e75e4c142007d577 (diff)
downloadslibtool-8a08048c6b3d4258b9d6ee206c22eb48b3d304fe.tar.bz2
slibtool-8a08048c6b3d4258b9d6ee206c22eb48b3d304fe.tar.xz
slbt_ar_parse_primary_armap_sysv_32(): properly handle empty string tables.
-rw-r--r--src/arbits/slbt_archive_meta.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/arbits/slbt_archive_meta.c b/src/arbits/slbt_archive_meta.c
index 9a9540f..45f47fd 100644
--- a/src/arbits/slbt_archive_meta.c
+++ b/src/arbits/slbt_archive_meta.c
@@ -508,7 +508,7 @@ static int slbt_ar_parse_primary_armap_sysv_32(
cap = memberp->ar_object_data;
cap += memberp->ar_object_size;
- if (cap == m->symstrs)
+ if ((cap == m->symstrs) && nsyms)
return SLBT_CUSTOM_ERROR(
dctx,
SLBT_ERR_AR_INVALID_ARMAP_STRING_TABLE);