From c02b2892a421b5a2aed7a3619f5ac1b3ce0548fd Mon Sep 17 00:00:00 2001 From: Stefano Karapetsas Date: Tue, 14 Oct 2014 10:51:08 +0200 Subject: pulse: Fix assertion if pulseaudio is not running --- backends/pulse/pulse-connection.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'backends') diff --git a/backends/pulse/pulse-connection.c b/backends/pulse/pulse-connection.c index 7344d2e..afd1e48 100644 --- a/backends/pulse/pulse-connection.c +++ b/backends/pulse/pulse-connection.c @@ -502,7 +502,8 @@ pulse_connection_disconnect (PulseConnection *connection) if (connection->priv->state == PULSE_CONNECTION_DISCONNECTED) return; - pa_context_unref (connection->priv->context); + if (connection->priv->context) + pa_context_unref (connection->priv->context); connection->priv->context = NULL; connection->priv->outstanding = 0; -- cgit v1.2.1