summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
Diffstat (limited to 'builtin')
-rw-r--r--builtin/fast-export.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/fast-export.c b/builtin/fast-export.c
index 85868162ee..289395a131 100644
--- a/builtin/fast-export.c
+++ b/builtin/fast-export.c
@@ -162,7 +162,7 @@ static const void *anonymize_mem(struct hashmap *map,
if (!ret) {
ret = xmalloc(sizeof(*ret));
hashmap_entry_init(&ret->hash, key.hash.hash);
- ret->orig = xstrdup(orig);
+ ret->orig = xmemdupz(orig, *len);
ret->orig_len = *len;
ret->anon = generate(orig, len);
ret->anon_len = *len;