aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/empathy-tube-dispatch.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/empathy-tube-dispatch.c b/src/empathy-tube-dispatch.c
index b1e7bce6d..63b31b2b6 100644
--- a/src/empathy-tube-dispatch.c
+++ b/src/empathy-tube-dispatch.c
@@ -167,9 +167,20 @@ empathy_tube_dispatch_constructed (GObject *object)
}
else if (!tp_strdiff (channel_type, EMP_IFACE_CHANNEL_TYPE_DBUS_TUBE))
{
+ GError *error = NULL;
+
type = TP_TUBE_TYPE_DBUS;
service = tp_asv_get_string (properties,
EMP_IFACE_CHANNEL_TYPE_DBUS_TUBE ".ServiceName");
+
+ if (!tp_dbus_check_valid_bus_name (service, TP_DBUS_NAME_TYPE_WELL_KNOWN,
+ &error))
+ {
+ DEBUG ("Can't dispatch tube; invalid ServiceName %s: %s", service,
+ error->message);
+ g_error_free (error);
+ goto failed;
+ }
}
else
{