Diff between 6fe28e354d9678b7363b75bebbb75952e8c180ec and 0212a969f6a96e575e2ffd0d3a3cfeb5d6712119

Changed Files

File Additions Deletions Status
android/avdtp.c +9 -0 modified

Full Patch

diff --git a/android/avdtp.c b/android/avdtp.c
index e93ff70..1783555 100644
--- a/android/avdtp.c
+++ b/android/avdtp.c
@@ -2832,10 +2832,19 @@ gboolean avdtp_stream_set_transport(struct avdtp_stream *stream, int fd,
 						size_t imtu, size_t omtu)
 {
 	GIOChannel *io;
+	int priority;
 
 	if (stream != stream->session->pending_open)
 		return FALSE;
 
+	priority = 5;
+	if (setsockopt(fd, SOL_SOCKET, SO_PRIORITY, &priority,
+						sizeof(priority)) < 0) {
+		error("setsockopt(SO_PRIORITY): %s (%d)", strerror(errno),
+									errno);
+		return FALSE;
+	}
+
 	io = g_io_channel_unix_new(fd);
 
 	handle_transport_connect(stream->session, io, imtu, omtu);