From: Simon McVittie Date: Tue, 21 Nov 2017 10:50:37 +0000 (+0000) Subject: test_peer_ping: Don't leak one method call per invocation X-Git-Tag: dbus-1.13.0~76 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=173f694b91d0bc3eb4eeffcd6154b78b275f7c88;p=thirdparty%2Fdbus.git test_peer_ping: Don't leak one method call per invocation Previously, we allocated m both during initialization, and after deciding not to skip this test. Signed-off-by: Simon McVittie Reviewed-by: Philip Withnall Bug: https://bugs.freedesktop.org/show_bug.cgi?id=103600 --- diff --git a/test/dbus-daemon.c b/test/dbus-daemon.c index f9d8f9233..3d5c147f9 100644 --- a/test/dbus-daemon.c +++ b/test/dbus-daemon.c @@ -1258,8 +1258,7 @@ static void test_peer_ping (Fixture *f, gconstpointer context) { - DBusMessage *m = dbus_message_new_method_call (DBUS_SERVICE_DBUS, - DBUS_PATH_DBUS, DBUS_INTERFACE_PEER, "Ping"); + DBusMessage *m = NULL; DBusPendingCall *pc = NULL; DBusError error = DBUS_ERROR_INIT;