blob: 30bd15e25b1c689248e1406de9df31d4e47c6a61 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
From b575cfb478df8b6b6bb81b149178fd66401788b1 Mon Sep 17 00:00:00 2001
From: John Vogel <jvogel@stygian.me>
Date: Sat, 14 Dec 2024 03:19:13 -0500
Subject: [PATCH] xcalloc argument cleanup.
---
export.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/export.c b/export.c
index 24c6161..5ab1ad7 100644
--- a/export.c
+++ b/export.c
@@ -798,9 +798,9 @@ void export_commits(forest_t *forest, export_options_t *opts,
export_stats.export_total_commits = export_ncommit(rl);
/* the +1 is because mark indices are 1-origin, slot 0 always empty */
- markmap = (serial_t *)xcalloc(sizeof(serial_t),
- forest->total_revisions +
+ markmap = (serial_t *)xcalloc(forest->total_revisions +
export_stats.export_total_commits + 1,
+ sizeof(serial_t),
"markmap allocation");
progress_begin("Generating snapshots...", forest->filecount);
--
2.47.1
|