Diff between c6dcf6b714501768ab7ea293e75d945be0eec188 and 72b02df3b2b40a3ac38832e2e80a16eb6b3bef04

Changed Files

File Additions Deletions Status
profiles/audio/a2dp.c +5 -0 modified

Full Patch

diff --git a/profiles/audio/a2dp.c b/profiles/audio/a2dp.c
index 6661a95..d8f24ea 100644
--- a/profiles/audio/a2dp.c
+++ b/profiles/audio/a2dp.c
@@ -636,6 +636,11 @@ static void a2dp_stream_free(void *data)
 {
 	struct a2dp_stream *stream = data;
 
+	if (stream->suspend_timer) {
+		timeout_remove(stream->suspend_timer);
+		stream->suspend_timer = 0;
+	}
+
 	avdtp_unref(stream->session);
 	free(stream);
 }