linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Santiago Carot-Nemesio <sancane@gmail.com>
To: linux-bluetooth@vger.kernel.org
Cc: Santiago Carot-Nemesio <sancane@gmail.com>
Subject: [PATCH 1/2] Fix memory leak if an error occurs when a data channel is reconnected.
Date: Fri, 25 Mar 2011 18:39:21 +0100	[thread overview]
Message-ID: <1301074762-26844-1-git-send-email-sancane@gmail.com> (raw)

---
 health/hdp.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/health/hdp.c b/health/hdp.c
index 3c2dce1..7a4b219 100644
--- a/health/hdp.c
+++ b/health/hdp.c
@@ -514,9 +514,9 @@ static void hdp_mdl_reconn_cb(struct mcap_mdl *mdl, GError *err, gpointer data)
 		reply = g_dbus_create_error(dc_data->msg,
 						ERROR_INTERFACE ".HealthError",
 						"Cannot get file descriptor");
-
-	reply = g_dbus_create_reply(dc_data->msg, DBUS_TYPE_UNIX_FD, &fd,
-							DBUS_TYPE_INVALID);
+	else
+		reply = g_dbus_create_reply(dc_data->msg, DBUS_TYPE_UNIX_FD,
+							&fd, DBUS_TYPE_INVALID);
 	g_dbus_send_message(dc_data->conn, reply);
 }
 
-- 
1.7.4.1


             reply	other threads:[~2011-03-25 17:39 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-25 17:39 Santiago Carot-Nemesio [this message]
2011-03-25 17:39 ` [PATCH 2/2] Emit missing signal when data channel is reconnected Santiago Carot-Nemesio
2011-03-27 19:52 ` [PATCH 1/2] Fix memory leak if an error occurs when a " Johan Hedberg

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=1301074762-26844-1-git-send-email-sancane@gmail.com \
    --to=sancane@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;
as well as URLs for NNTP newsgroup(s).