All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sathish N <sathish.n@globaledgesoft.com>
To: linux-bluetooth@vger.kernel.org
Cc: girish.br@globaledgesoft.com, sathish.n@globaledgesoft.com,
	ajay.kv@globaledgesoft.com, anderson.lizardo@openbossa.org
Subject: [PATCH bluez] attrib: Fix interactive gatttool segfault
Date: Thu, 18 Jul 2013 16:12:36 +0530	[thread overview]
Message-ID: <1374144156-16351-1-git-send-email-sathish.n@globaledgesoft.com> (raw)

From: sathish N <sathish.n@globaledgesoft.com>

---
 bluez/attrib/interactive.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/bluez/attrib/interactive.c b/bluez/attrib/interactive.c
index f28dc22..4fd7276 100644
--- a/bluez/attrib/interactive.c
+++ b/bluez/attrib/interactive.c
@@ -867,7 +867,8 @@ static void parse_line(char *line_read)
 
 	add_history(line_read);
 
-	g_shell_parse_argv(line_read, &argcp, &argvp, NULL);
+	if (g_shell_parse_argv(line_read, &argcp, &argvp, NULL) == FALSE)
+		goto done;
 
 	for (i = 0; commands[i].cmd; i++)
 		if (strcasecmp(commands[i].cmd, argvp[0]) == 0)
-- 
1.7.9.5

             reply	other threads:[~2013-07-18 10:42 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-18 10:42 Sathish N [this message]
2013-07-18 11:16 ` [PATCH bluez] attrib: Fix interactive gatttool segfault Johan Hedberg
2013-07-18 14:03   ` Sathish N
2013-07-18 14:02 [PATCH BlueZ] attrib: Fix interactive gatttool Segfault Sathish Narasimman
2013-07-19  4:31 [PATCH BlueZ] attrib: Fix interactive gatttool segfault Sathish Narasimman
2013-07-19 11:03 ` Anderson Lizardo
2013-07-19 11:26 ` 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=1374144156-16351-1-git-send-email-sathish.n@globaledgesoft.com \
    --to=sathish.n@globaledgesoft.com \
    --cc=ajay.kv@globaledgesoft.com \
    --cc=anderson.lizardo@openbossa.org \
    --cc=girish.br@globaledgesoft.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.