Revert CVS revision 1.68; it is now possible for entry to be NULL at the end

of write_entry.  (This was perfectly safe, since archive_entry_free(NULL) is
a no-op, but adding the check back makes the style more consistent.)
This commit is contained in:
Colin Percival 2008-07-05 02:21:51 +00:00
parent 6481fd43de
commit 9af6e14a8c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=180277

View file

@ -950,7 +950,8 @@ write_entry(struct bsdtar *bsdtar, struct archive *a, const struct stat *st,
if (fd >= 0)
close(fd);
archive_entry_free(entry);
if (entry != NULL)
archive_entry_free(entry);
}