mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-03-03 06:32:10 +01:00
GDBusProxy: Also check signature when checking if signal is expected
Signed-off-by: David Zeuthen <davidz@redhat.com>
This commit is contained in:
parent
caf993df6f
commit
f516ebc57b
@ -758,9 +758,17 @@ on_signal_received (GDBusConnection *connection,
|
|||||||
if (proxy->priv->expected_interface != NULL)
|
if (proxy->priv->expected_interface != NULL)
|
||||||
{
|
{
|
||||||
const GDBusSignalInfo *info;
|
const GDBusSignalInfo *info;
|
||||||
|
GVariantType *expected_type;
|
||||||
info = g_dbus_interface_info_lookup_signal (proxy->priv->expected_interface, signal_name);
|
info = g_dbus_interface_info_lookup_signal (proxy->priv->expected_interface, signal_name);
|
||||||
if (info == NULL)
|
if (info == NULL)
|
||||||
goto out;
|
goto out;
|
||||||
|
expected_type = _g_dbus_compute_complete_signature (info->args);
|
||||||
|
if (!g_variant_type_equal (expected_type, g_variant_get_type (parameters)))
|
||||||
|
{
|
||||||
|
g_variant_type_free (expected_type);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
g_variant_type_free (expected_type);
|
||||||
}
|
}
|
||||||
|
|
||||||
g_signal_emit (proxy,
|
g_signal_emit (proxy,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user