From: =?unknown-8bit?q?Fr=C3=A9d=C3=A9ric?= Dalleau <frederic.dalleau@linux.intel.com>
To: ofono@ofono.org
Subject: [PATCH] gatchat: Fix reentrency issue with empty commands
Date: Thu, 07 Jul 2011 16:19:29 +0200 [thread overview]
Message-ID: <1310048369-31394-2-git-send-email-frederic.dalleau@linux.intel.com> (raw)
In-Reply-To: <1310048369-31394-1-git-send-email-frederic.dalleau@linux.intel.com>
[-- Attachment #1: Type: text/plain, Size: 607 bytes --]
Emulator response to empty command is sent twice
---
gatchat/gatserver.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/gatchat/gatserver.c b/gatchat/gatserver.c
index 3a996cb..a29e489 100644
--- a/gatchat/gatserver.c
+++ b/gatchat/gatserver.c
@@ -1008,6 +1008,9 @@ static void new_bytes(struct ring_buffer *rbuf, gpointer user_data)
unsigned char *buf = ring_buffer_read_ptr(rbuf, p->read_so_far);
enum ParserResult result;
+ if (p->in_read_handler)
+ return;
+
p->in_read_handler = TRUE;
while (p->io && (p->read_so_far < len)) {
--
1.7.1
prev parent reply other threads:[~2011-07-07 14:19 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-07 14:19 [PATCH] Fix issue with AT parser in gatserver =?unknown-8bit?q?Fr=C3=A9d=C3=A9ric?= Dalleau
2011-07-07 6:02 ` Denis Kenzior
2011-07-08 14:44 ` Dalleau, Frederic
2011-07-11 21:25 ` Denis Kenzior
2011-07-07 14:19 ` =?unknown-8bit?q?Fr=C3=A9d=C3=A9ric?= Dalleau [this message]
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=1310048369-31394-2-git-send-email-frederic.dalleau@linux.intel.com \
--to=frederic.dalleau@linux.intel.com \
--cc=ofono@ofono.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