summaryrefslogtreecommitdiffstats
path: root/contrib/libarchive/libarchive/archive_entry_stat.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/libarchive/libarchive/archive_entry_stat.c')
-rw-r--r--contrib/libarchive/libarchive/archive_entry_stat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/libarchive/libarchive/archive_entry_stat.c b/contrib/libarchive/libarchive/archive_entry_stat.c
index cdaeac3..2edc5d2 100644
--- a/contrib/libarchive/libarchive/archive_entry_stat.c
+++ b/contrib/libarchive/libarchive/archive_entry_stat.c
@@ -41,7 +41,7 @@ archive_entry_stat(struct archive_entry *entry)
{
struct stat *st;
if (entry->stat == NULL) {
- entry->stat = malloc(sizeof(*st));
+ entry->stat = calloc(1, sizeof(*st));
if (entry->stat == NULL)
return (NULL);
entry->stat_valid = 0;
@@ -110,7 +110,7 @@ archive_entry_stat(struct archive_entry *entry)
/*
* TODO: On Linux, store 32 or 64 here depending on whether
* the cached stat structure is a stat32 or a stat64. This
- * will allow us to support both variants interchangably.
+ * will allow us to support both variants interchangeably.
*/
entry->stat_valid = 1;
OpenPOWER on IntegriCloud