Linux bluetooth development
 help / color / mirror / Atom feed
From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: PATCH] Fix not emitting error properly when sco connection fails
Date: Fri, 5 Mar 2010 15:00:31 +0200	[thread overview]
Message-ID: <2d5a2c101003050500m2530d2a9n8bcae529e540c726@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 508 bytes --]

---
 audio/headset.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/audio/headset.c b/audio/headset.c
index 15d3672..0176937 100644
--- a/audio/headset.c
+++ b/audio/headset.c
@@ -573,6 +573,7 @@ static void sco_connect_cb(GIOChannel *chan,
GError *err, gpointer user_data)

 	if (err) {
 		error("%s", err->message);
+		p->err = -errno;

 		if (p && p->msg)
 			error_connection_attempt_failed(dev->conn, p->msg, p->err);
-- 
1.6.3.3


-- 
Luiz Augusto von Dentz
Computer Engineer

[-- Attachment #2: 0010-Fix-not-emitting-error-properly-when-sco-connection-.patch --]
[-- Type: text/x-patch, Size: 710 bytes --]

From dfcc6b0bfd8ed75630968dbb4967c31f6a0dd39a Mon Sep 17 00:00:00 2001
From: Luiz Augusto Von Dentz <luiz.dentz-von@nokia.com>
Date: Fri, 5 Mar 2010 14:19:58 +0200
Subject: [PATCH 10/11] Fix not emitting error properly when sco connection fails

---
 audio/headset.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/audio/headset.c b/audio/headset.c
index 15d3672..0176937 100644
--- a/audio/headset.c
+++ b/audio/headset.c
@@ -573,6 +573,7 @@ static void sco_connect_cb(GIOChannel *chan, GError *err, gpointer user_data)
 
 	if (err) {
 		error("%s", err->message);
+		p->err = -errno;
 
 		if (p && p->msg)
 			error_connection_attempt_failed(dev->conn, p->msg, p->err);
-- 
1.6.3.3


                 reply	other threads:[~2010-03-05 13:00 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2d5a2c101003050500m2530d2a9n8bcae529e540c726@mail.gmail.com \
    --to=luiz.dentz@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox