From: Tim Kientzle Date: Sun, 4 May 2008 20:08:45 +0000 (-0400) Subject: Clear the link resolver structure on initialization; this fixes X-Git-Tag: v2.6.0~271 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9f2d408bd7887203f27a2f515ea301821668c5ba;p=thirdparty%2Flibarchive.git Clear the link resolver structure on initialization; this fixes a crash when the link resolver is cleaned up. SVN-Revision: 21 --- diff --git a/libarchive/archive_entry_link_resolver.c b/libarchive/archive_entry_link_resolver.c index 70c470c3b..7a34b272f 100644 --- a/libarchive/archive_entry_link_resolver.c +++ b/libarchive/archive_entry_link_resolver.c @@ -327,6 +327,7 @@ insert_entry(struct archive_entry_linkresolver *res, le = malloc(sizeof(struct links_entry)); if (le == NULL) return (NULL); + memset(le, 0, sizeof(*le)); le->canonical = archive_entry_clone(entry); /* If the links cache is getting too full, enlarge the hash table. */