aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--changes/cid14441193
-rw-r--r--src/feature/dircommon/consdiff.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/changes/cid1444119 b/changes/cid1444119
new file mode 100644
index 0000000000..bb6854e66f
--- /dev/null
+++ b/changes/cid1444119
@@ -0,0 +1,3 @@
+ o Minor bugfixes (C correctness):
+ - Fix an unlikely memory leak in consensus_diff_apply(). Fixes bug 29824;
+ bugfix on 0.3.1.1-alpha. This is Coverity warning CID 1444119.
diff --git a/src/feature/dircommon/consdiff.c b/src/feature/dircommon/consdiff.c
index 698f548013..8e93953f73 100644
--- a/src/feature/dircommon/consdiff.c
+++ b/src/feature/dircommon/consdiff.c
@@ -1389,7 +1389,7 @@ consensus_diff_apply(const char *consensus,
r1 = consensus_compute_digest_as_signed(consensus, consensus_len, &d1);
if (BUG(r1 < 0))
- return NULL; // LCOV_EXCL_LINE
+ goto done;
lines1 = smartlist_new();
lines2 = smartlist_new();