aboutsummaryrefslogtreecommitdiff
path: root/lib/libarchive/archive_entry.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libarchive/archive_entry.c')
-rw-r--r--lib/libarchive/archive_entry.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/libarchive/archive_entry.c b/lib/libarchive/archive_entry.c
index 8ca69fe422b9..cc7e4d30582b 100644
--- a/lib/libarchive/archive_entry.c
+++ b/lib/libarchive/archive_entry.c
@@ -307,6 +307,8 @@ aes_copy_wcs_len(struct aes *aes, const wchar_t *wcs, size_t len)
struct archive_entry *
archive_entry_clear(struct archive_entry *entry)
{
+ if (entry == NULL)
+ return (NULL);
aes_clean(&entry->ae_fflags_text);
aes_clean(&entry->ae_gname);
aes_clean(&entry->ae_hardlink);