diff --git a/profiles/audio/avctp.c b/profiles/audio/avctp.c
index 41e2f46..303427e 100644
--- a/profiles/audio/avctp.c
+++ b/profiles/audio/avctp.c
break;
case AVCTP_STATE_CONNECTED:
DBG("AVCTP Connected");
- if (session->browsing) {
- avctp_channel_destroy(session->browsing);
- session->browsing = NULL;
- }
break;
case AVCTP_STATE_BROWSING_CONNECTING:
DBG("AVCTP Browsing Connecting");
failed:
DBG("AVCTP Browsing: disconnected");
+ avctp_set_state(session, AVCTP_STATE_CONNECTED);
+
+ if (session->browsing) {
+ avctp_channel_destroy(session->browsing);
+ session->browsing = NULL;
+ }
+
return FALSE;
}