From: Ralf Habacker Date: Mon, 12 Mar 2018 14:28:50 +0000 (+0100) Subject: Remove obsolete call to _dbus_string_free() in unix variant of _dbus_connect_tcp_sock... X-Git-Tag: dbus-1.13.4~36 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9d1cdce2b4892eb2204533c8ea68466fa9dd1441;p=thirdparty%2Fdbus.git Remove obsolete call to _dbus_string_free() in unix variant of _dbus_connect_tcp_socket_with_nonce A DBusString that was initialized with a constant doesn't hold any allocated memory, so it doesn't need to be freed. Reviewed-by: Simon McVittie https://bugs.freedesktop.org/show_bug.cgi?id=61922 --- diff --git a/dbus/dbus-sysdeps-unix.c b/dbus/dbus-sysdeps-unix.c index 73c59acbc..249cf77e9 100644 --- a/dbus/dbus-sysdeps-unix.c +++ b/dbus/dbus-sysdeps-unix.c @@ -1454,7 +1454,6 @@ _dbus_connect_tcp_socket_with_nonce (const char *host, dbus_bool_t ret; _dbus_string_init_const (&noncefileStr, noncefile); ret = _dbus_send_nonce (fd, &noncefileStr, error); - _dbus_string_free (&noncefileStr); if (!ret) {