Limit HFP plugin loading to D-Bus 1.3 only systems
authorMarcel Holtmann <marcel@holtmann.org>
Wed, 27 Jan 2010 20:16:26 +0000 (21:16 +0100)
committerMarcel Holtmann <marcel@holtmann.org>
Wed, 27 Jan 2010 20:18:07 +0000 (21:18 +0100)
plugins/hfp.c

index 12b7f0a..947bfc2 100644 (file)
@@ -811,6 +811,9 @@ static int hfp_init(void)
 {
        int err;
 
+       if (DBUS_TYPE_UNIX_FD < 0)
+               return -EBADF;
+
        connection = ofono_dbus_get_connection();
 
        added_watch = g_dbus_add_signal_watch(connection, NULL, NULL,