summaryrefslogtreecommitdiffstats
path: root/usr.bin/tar/write.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/tar/write.c')
-rw-r--r--usr.bin/tar/write.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/usr.bin/tar/write.c b/usr.bin/tar/write.c
index 8fe0530..9b3f39b 100644
--- a/usr.bin/tar/write.c
+++ b/usr.bin/tar/write.c
@@ -1100,8 +1100,7 @@ lookup_hardlink(struct bsdtar *bsdtar, struct archive_entry *entry,
le->previous->next = le->next;
if (le->next != NULL)
le->next->previous = le->previous;
- if (le->name != NULL)
- free(le->name);
+ free(le->name);
if (links_cache->buckets[hash] == le)
links_cache->buckets[hash] = le->next;
links_cache->number_entries--;
OpenPOWER on IntegriCloud