Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-8]: src/usr.sbin/bta2dpd/bta2dpd Pull up following revision(s) (r...
details: https://anonhg.NetBSD.org/src/rev/8889bbf07652
branches: netbsd-8
changeset: 434264:8889bbf07652
user: martin <martin%NetBSD.org@localhost>
date: Thu Aug 31 11:21:43 2017 +0000
description:
Pull up following revision(s) (requested by nat in ticket #242):
usr.sbin/bta2dpd/bta2dpd/bta2dpd.c: revision 1.4
Connection state machine improvement upon transition from AVDTP_OPEN to
AVDTP_START/SUSPEND.
diffstat:
usr.sbin/bta2dpd/bta2dpd/bta2dpd.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diffs (38 lines):
diff -r 2ae3b90843ad -r 8889bbf07652 usr.sbin/bta2dpd/bta2dpd/bta2dpd.c
--- a/usr.sbin/bta2dpd/bta2dpd/bta2dpd.c Thu Aug 31 11:19:58 2017 +0000
+++ b/usr.sbin/bta2dpd/bta2dpd/bta2dpd.c Thu Aug 31 11:21:43 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bta2dpd.c,v 1.3 2017/05/27 10:04:57 nat Exp $ */
+/* $NetBSD: bta2dpd.c,v 1.3.2.1 2017/08/31 11:21:43 martin Exp $ */
/*-
* Copyright (c) 2015 - 2016 Nathanial Sloss <nathanialsloss%yahoo.com.au@localhost>
@@ -674,7 +674,8 @@
case AVDTP_SUSPEND:
case AVDTP_START:
avdtpSendAccept(fd, fd, trans, signal);
- state = 6;
+ if (state < 6)
+ state = 6;
break;
default:
avdtpSendReject(fd, fd, trans, signal);
@@ -717,7 +718,8 @@
break;
case AVDTP_SUSPEND:
case AVDTP_START:
- state = 6;
+ if (state < 6)
+ state = 6;
break;
default:
avdtpSendReject(fd, fd, trans, signal);
@@ -730,7 +732,7 @@
if (state < 5 || state > 7)
return;
- if (asSpeaker) {
+ if (asSpeaker && state == 6) {
len = sizeof(addr);
if ((sc = accept(orighc,(struct sockaddr*)&addr, &len)) < 0)
err(EXIT_FAILURE, "stream accept");
Home |
Main Index |
Thread Index |
Old Index