chiark / gitweb /
test-dhcp-option: fix memleak
authorTom Gundersen <teg@jklm.no>
Sun, 25 May 2014 15:34:17 +0000 (17:34 +0200)
committerTom Gundersen <teg@jklm.no>
Mon, 26 May 2014 19:31:57 +0000 (21:31 +0200)
src/libsystemd-network/test-dhcp-option.c

index 4482a6783cb4ae02068e4f60e5476a9e00b8e5b2..92c58e0d58e5edebbbe418a474845c5ea2eda3da 100644 (file)
@@ -300,7 +300,7 @@ static uint8_t options[64] = {
 
 static void test_option_set(void)
 {
-        DHCPMessage *result;
+        _cleanup_free_ DHCPMessage *result = NULL;
         size_t offset = 0, len, pos;
         unsigned i;