diff options
-rw-r--r-- | src/sound-service-dbus.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/sound-service-dbus.c b/src/sound-service-dbus.c index 1b9d29e..ea96e6a 100644 --- a/src/sound-service-dbus.c +++ b/src/sound-service-dbus.c @@ -237,6 +237,12 @@ sound_service_dbus_update_sound_state (SoundServiceDbus* self, GError * error = NULL; + if (priv->connection == NULL || + g_dbus_connection_is_closed (priv->connection) == TRUE){ + g_warning ("sound_service_dbus_update_sound_state - connection no good !!"); + return; + } + g_debug ("emitting state signal with value %i", (int)new_state); g_dbus_connection_emit_signal( priv->connection, NULL, |