summaryrefslogtreecommitdiff
path: root/packfile.c
diff options
context:
space:
mode:
Diffstat (limited to 'packfile.c')
-rw-r--r--packfile.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/packfile.c b/packfile.c
index 1a714fb..7cd45aa 100644
--- a/packfile.c
+++ b/packfile.c
@@ -1454,6 +1454,9 @@ static void *unpack_compressed_entry(struct packed_git *p,
return NULL;
}
+ /* versions of zlib can clobber unconsumed portion of outbuf */
+ buffer[size] = '\0';
+
return buffer;
}