Diff between 4d58eb52bcc179efb66953647cabdc07b2a9c9ec and 11a57b5c267d310bc0fd20d51fc4286bbda12697

Changed Files

File Additions Deletions Status
profiles/audio/control.c +1 -1 modified

Full Patch

diff --git a/profiles/audio/control.c b/profiles/audio/control.c
index edc4a98..707276d 100644
--- a/profiles/audio/control.c
+++ b/profiles/audio/control.c
@@ -127,7 +127,7 @@ int control_disconnect(struct btd_service *service)
 {
 	struct control *control = btd_service_get_user_data(service);
 
-	if (!control->session)
+	if (!control || !control->session)
 		return -ENOTCONN;
 
 	avctp_disconnect(control->session);