From ee71b68b4b3efcbeaea6adea17bcdf960a85c562 Mon Sep 17 00:00:00 2001 From: cperciva Date: Mon, 19 May 2008 18:09:26 +0000 Subject: There's no way for entry to possibly be NULL at the end of write_entry (in fact, there has never been any way for it to be NULL, going all the way back to revision 1.1 of this file), so remove the check and unconditionally free entry. Found by: Coverity Prevent --- usr.bin/tar/write.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/usr.bin/tar/write.c b/usr.bin/tar/write.c index ec83b60..8fe0530 100644 --- a/usr.bin/tar/write.c +++ b/usr.bin/tar/write.c @@ -932,8 +932,7 @@ abort: if (fd >= 0) close(fd); - if (entry != NULL) - archive_entry_free(entry); + archive_entry_free(entry); } -- cgit v1.1