diff --git a/src/pulsecore/protocol-esound.c b/src/pulsecore/protocol-esound.c index cac4e36c7..2b80c65ff 100644 --- a/src/pulsecore/protocol-esound.c +++ b/src/pulsecore/protocol-esound.c @@ -1290,6 +1290,9 @@ static int connection_process_msg(pa_msgobject *o, int code, void*userdata, int6 connection *c = CONNECTION(o); connection_assert_ref(c); + if (!c->protocol) + return -1; + switch (code) { case CONNECTION_MESSAGE_REQUEST_DATA: do_work(c); diff --git a/src/pulsecore/protocol-simple.c b/src/pulsecore/protocol-simple.c index b43245a41..44fe5973d 100644 --- a/src/pulsecore/protocol-simple.c +++ b/src/pulsecore/protocol-simple.c @@ -283,6 +283,9 @@ static int connection_process_msg(pa_msgobject *o, int code, void*userdata, int6 connection *c = CONNECTION(o); connection_assert_ref(c); + if (!c->protocol) + return -1; + switch (code) { case CONNECTION_MESSAGE_REQUEST_DATA: do_work(c);