Fix ignore incoming bytes during parsing

Server processes one command line at one time, so ignore the rest
incoming bytes during the command parsing.
This commit is contained in:
Zhenhua Zhang 2010-03-31 10:40:08 +08:00 committed by Denis Kenzior
parent 1f5e785901
commit c288921bab
1 changed files with 4 additions and 0 deletions

View File

@ -771,6 +771,10 @@ static gboolean received_data(GIOChannel *channel, GIOCondition cond,
g_at_util_debug_chat(TRUE, (char *)buf, rbytes,
server->debugf, server->debug_data);
/* Ignore incoming bytes when processing a command line */
if (server->processing_cmdline)
continue;
read_count++;
total_read += rbytes;