[PATCH obexd 09/14] Add psm parameter for session_find.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



---
 client/session.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
 mode change 100644 => 100755 client/session.c

diff --git a/client/session.c b/client/session.c
old mode 100644
new mode 100755
index dd08610..3db1c1d
--- a/client/session.c
+++ b/client/session.c
@@ -498,6 +498,7 @@ static struct session_data *session_find(const char *source,
 						const char *destination,
 						const char *service,
 						uint8_t channel,
+						uint16_t psm,
 						const char *owner)
 {
 	GSList *l;
@@ -519,7 +520,8 @@ static struct session_data *session_find(const char *source,
 		if (g_strcmp0(service, session->service))
 			continue;

-		if (channel && session->channel != channel)
+		if ((channel && session->channel != channel)
+			&&(psm && session->psm != psm))
 			continue;

 		if (g_strcmp0(owner, session->owner))
@@ -547,7 +549,7 @@ struct session_data *session_create(const char *source,
 	if (destination == NULL)
 		return NULL;

-	session = session_find(source, destination, service, channel, owner);
+	session = session_find(source, destination, service, channel, psm, owner);
 	if (session) {
 		session_ref(session);
 		goto proceed;
--
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux