diff options
author | Claudio Takahasi <claudio.takahasi@openbossa.org> | 2013-03-04 17:48:52 -0300 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2013-03-04 16:41:51 -0600 |
commit | a6874a64b2c4ff377549dbf1a81ce3bec809e03a (patch) | |
tree | 74dde1c16c117167cdf8e2d1a0a111eef5b4cbfc | |
parent | 2c4015278d1b1347228360dc2de3831ae0bd688a (diff) | |
download | ofono-a6874a64b2c4ff377549dbf1a81ce3bec809e03a.tar.bz2 |
handsfree-audio: Reject SCO if Card is not ready
The Audio Card is being created when the NewConnection from BlueZ
Profile is received, and registered when the service level connection
negotiation finishes. This patch rejects SCO connection if the SCO
incoming connection arrives when the service level negotiation is
ongoing.
-rw-r--r-- | src/handsfree-audio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/handsfree-audio.c b/src/handsfree-audio.c index 14872b0e..857c258d 100644 --- a/src/handsfree-audio.c +++ b/src/handsfree-audio.c @@ -138,7 +138,7 @@ static gboolean sco_accept(GIOChannel *io, GIOCondition cond, bt_ba2str(&saddr.sco_bdaddr, local); card = card_find(remote, local); - if (card == NULL) { + if (card == NULL || card->path == NULL) { ofono_error("Rejecting SCO: Audio Card not found!"); close(nsk); return TRUE; |