Commit 64a1d59b authored by Ralf Habacker's avatar Ralf Habacker

Windows _dbus_connect_tcp_socket_with_nonce: Simplify initialization of variable noncefileStr

This optimization has been detected while comparing the related unix
Reviewed-by: Simon McVittie's avatarSimon McVittie <>
parent 9d1cdce2
......@@ -1611,18 +1611,9 @@ _dbus_connect_tcp_socket_with_nonce (const char *host,
DBusString noncefileStr;
dbus_bool_t ret;
if (!_dbus_string_init (&noncefileStr) ||
!_dbus_string_append(&noncefileStr, noncefile))
closesocket (fd.sock);
dbus_set_error (error, DBUS_ERROR_NO_MEMORY, NULL);
return _dbus_socket_get_invalid ();
_dbus_string_init_const (&noncefileStr, noncefile);
ret = _dbus_send_nonce (fd, &noncefileStr, error);
_dbus_string_free (&noncefileStr);
if (!ret)
closesocket (fd.sock);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment