View Issue Details

IDProjectCategoryView StatusLast Update
0007630GNUnettesting librarypublic2023-06-01 18:26
Reporterulfvonbelow Assigned Tot3sserakt Due Date
PrioritynormalSeveritytrivialReproducibilityalways
Status closedResolutionfixed 
Product VersionGit master 
Target Version0.19.4 
Summary0007630: Memory leak in (?) finish_test in testing_api_loop.c
DescriptionThe barriers are never freed. I don't know whether this is the job of the testing library or the caller.
Steps To Reproduce./configure --enable-sanitizer
make
make install
make check
Additional InformationIf it's the testing library's job to free the barriers, then the attached patch will do that. Otherwise, we have an incorrect test case somewhere that isn't freeing them (I don't remember which).
Tagsmemory-leak, patch
Attached Files
0001-TESTING-don-t-leak-barriers.patch (684 bytes)   
From 001a8272d906a2a358d986b82a6082217e4525e2 Mon Sep 17 00:00:00 2001
From: ulfvonbelow <strilen@tilde.club>
Date: Sun, 29 Jan 2023 05:56:32 -0600
Subject: [PATCH] TESTING: don't leak barriers.

---
 src/testing/testing_api_loop.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/testing/testing_api_loop.c b/src/testing/testing_api_loop.c
index 7d719afc0..fc9f04c48 100644
--- a/src/testing/testing_api_loop.c
+++ b/src/testing/testing_api_loop.c
@@ -285,6 +285,7 @@ finish_test (void *cls)
   GNUNET_free (is->commands);
   is->rc (is->rc_cls,
           is->result);
+  TST_interpreter_delete_barriers (is);
   GNUNET_free (is->helper);
   GNUNET_free (is);
 }
-- 
2.38.1

Activities

t3sserakt

2023-02-07 16:44

developer   ~0019772

Fix committed to master branch.

schanzen

2023-06-01 18:26

administrator   ~0020214

released some time ago

Issue History

Date ModifiedUsernameFieldChange
2023-01-29 21:33ulfvonbelowNew Issue
2023-01-29 21:33ulfvonbelowTag Attached: memory-leak
2023-01-29 21:33ulfvonbelowTag Attached: patch
2023-01-29 21:33ulfvonbelowFile Added: 0001-TESTING-don-t-leak-barriers.patch
2023-02-06 05:11schanzenAssigned To => t3sserakt
2023-02-06 05:11schanzenStatusnew => assigned
2023-02-06 05:11schanzenTarget Version => 0.19.4
2023-02-07 16:44t3sserakt
2023-02-07 16:44t3sseraktNote Added: 0019772
2023-02-07 16:44t3sseraktStatusassigned => resolved
2023-02-07 16:44t3sseraktResolutionopen => fixed
2023-06-01 18:26schanzenNote Added: 0020214
2023-06-01 18:26schanzenStatusresolved => closed