diff options
Diffstat (limited to 'archival/libarchive/unpack_ar_archive.c')
-rw-r--r-- | archival/libarchive/unpack_ar_archive.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/archival/libarchive/unpack_ar_archive.c b/archival/libarchive/unpack_ar_archive.c index 214d17e..0bc0303 100644 --- a/archival/libarchive/unpack_ar_archive.c +++ b/archival/libarchive/unpack_ar_archive.c @@ -12,7 +12,7 @@ void FAST_FUNC unpack_ar_archive(archive_handle_t *ar_archive) char magic[7]; xread(ar_archive->src_fd, magic, AR_MAGIC_LEN); - if (strncmp(magic, AR_MAGIC, AR_MAGIC_LEN) != 0) { + if (!is_prefixed_with(magic, AR_MAGIC)) { bb_error_msg_and_die("invalid ar magic"); } ar_archive->offset += AR_MAGIC_LEN; |