mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-13 06:33:44 +01:00
fix a coverity resource leak warning
This commit is contained in:
parent
4e6b13a38a
commit
8cb08f716d
@ -5736,7 +5736,7 @@ test_util_get_unquoted_path(void *arg)
|
|||||||
{
|
{
|
||||||
(void)arg;
|
(void)arg;
|
||||||
|
|
||||||
char *r;
|
char *r = NULL;
|
||||||
|
|
||||||
r = get_unquoted_path("\""); // "
|
r = get_unquoted_path("\""); // "
|
||||||
tt_ptr_op(r, OP_EQ, NULL);
|
tt_ptr_op(r, OP_EQ, NULL);
|
||||||
@ -5804,10 +5804,9 @@ test_util_get_unquoted_path(void *arg)
|
|||||||
|
|
||||||
r = get_unquoted_path("\"A\\B\\\"C\""); // "A\B\"C"
|
r = get_unquoted_path("\"A\\B\\\"C\""); // "A\B\"C"
|
||||||
tt_str_op(r, OP_EQ, "A\\B\"C"); // A\B"C
|
tt_str_op(r, OP_EQ, "A\\B\"C"); // A\B"C
|
||||||
tor_free(r);
|
|
||||||
|
|
||||||
done:
|
done:
|
||||||
;
|
tor_free(r);
|
||||||
}
|
}
|
||||||
|
|
||||||
#define UTIL_LEGACY(name) \
|
#define UTIL_LEGACY(name) \
|
||||||
|
Loading…
Reference in New Issue
Block a user