mgcp_test: fix possible double free

Change-Id: I2d044382c0bb66e190400e3397449c3f2387359a
This commit is contained in:
Philipp Maier
2017-12-04 17:16:16 +01:00
parent 7df419b434
commit a330b864e5

View File

@@ -685,7 +685,8 @@ static void test_messages(void)
printf("(response does not contain a connection id)\n");
}
msgb_free(msg);
if (msg)
msgb_free(msg);
if (dummy_packets)
printf("Dummy packets: %d\n", dummy_packets);