openbsc[master]: tests: fix leaks by talloc ctx

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Thu Feb 9 13:06:54 UTC 2017


Patch Set 2:

(1 comment)

https://gerrit.osmocom.org/#/c/1751/2/openbsc/tests/gtphub/gtphub_test.c
File openbsc/tests/gtphub/gtphub_test.c:

Line 1784: 	talloc_free(osmo_gtphub_ctx);
I'm not sure this makes sense. The line above verifies that there are no memleaks, and when the test exits, the entire memory of the process will be freed. ... BTW the source code for the 'git' program does this generally: it hardly ever frees anything because it assumes to be a short-lived process to be cleaned up by the kernel on exit ;)


-- 
To view, visit https://gerrit.osmocom.org/1751
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I5bba63ed4e4cf23501063dd03bf38eee9945c163
Gerrit-PatchSet: 2
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-HasComments: Yes


More information about the gerrit-log mailing list