From: "Gustavo F. Padovan" <padovan@profusion.mobi>
To: linux-bluetooth@vger.kernel.org
Cc: "Gustavo F. Padovan" <padovan@profusion.mobi>
Subject: [PATCH] avdtp: check if the socket is valid
Date: Tue, 18 Oct 2011 18:03:06 -0200 [thread overview]
Message-ID: <1318968186-6202-1-git-send-email-padovan@profusion.mobi> (raw)
From: "Gustavo F. Padovan" <padovan@profusion.mobi>
---
audio/avdtp.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/audio/avdtp.c b/audio/avdtp.c
index d3568ba..08860d2 100644
--- a/audio/avdtp.c
+++ b/audio/avdtp.c
@@ -523,6 +523,8 @@ static gboolean avdtp_send(struct avdtp *session, uint8_t transaction,
}
sock = g_io_channel_unix_get_fd(session->io);
+ if (!sock)
+ return FALSE;
/* Single packet - no fragmentation */
if (sizeof(struct avdtp_single_header) + len <= session->omtu) {
--
1.7.6.4
next reply other threads:[~2011-10-18 20:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-18 20:03 Gustavo F. Padovan [this message]
2011-10-20 11:19 ` [PATCH] avdtp: check if the socket is valid 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=1318968186-6202-1-git-send-email-padovan@profusion.mobi \
--to=padovan@profusion.mobi \
--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