diff --git a/gio/gdbusauth.c b/gio/gdbusauth.c index 17c7d47b7..24189290b 100644 --- a/gio/gdbusauth.c +++ b/gio/gdbusauth.c @@ -784,13 +784,13 @@ _g_dbus_auth_run_client (GDBusAuth *auth, if (line == NULL) goto out; debug_print ("CLIENT: WaitingForData, read='%s'", line); - if (g_str_has_prefix (line, "DATA ")) + if (g_str_equal (line, "DATA") || g_str_has_prefix (line, "DATA ")) { gchar *encoded; gchar *decoded_data; gsize decoded_data_len = 0; - encoded = g_strdup (line + 5); + encoded = g_strdup (line + 4); g_free (line); g_strstrip (encoded); decoded_data = hexdecode (encoded, &decoded_data_len, error); @@ -1284,13 +1284,13 @@ _g_dbus_auth_run_server (GDBusAuth *auth, debug_print ("SERVER: WaitingForData, read '%s'", line); if (line == NULL) goto out; - if (g_str_has_prefix (line, "DATA ")) + if (g_str_equal (line, "DATA") || g_str_has_prefix (line, "DATA ")) { gchar *encoded; gchar *decoded_data; gsize decoded_data_len = 0; - encoded = g_strdup (line + 5); + encoded = g_strdup (line + 4); g_free (line); g_strstrip (encoded); decoded_data = hexdecode (encoded, &decoded_data_len, error);