Author: brueffer Date: Fri Feb 21 09:25:52 2014 New Revision: 262287 URL: http://svnweb.freebsd.org/changeset/base/262287
Log: MFC: r261900 In chat_UpdateSet(), initialize the input buffer to prevent stale data from previous timed out commands. PR: 186530 Submitted by: Alexander Zagrebin <alexz at visp.ru> Reviewed by: brian Modified: stable/10/usr.sbin/ppp/chat.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/ppp/chat.c ============================================================================== --- stable/10/usr.sbin/ppp/chat.c Fri Feb 21 09:22:37 2014 (r262286) +++ stable/10/usr.sbin/ppp/chat.c Fri Feb 21 09:25:52 2014 (r262287) @@ -154,6 +154,11 @@ chat_UpdateSet(struct fdescriptor *d, fd else { /* c->state = CHAT_EXPECT; */ c->argptr = &arg_term; + /* + We have to clear the input buffer, because it contains output + from the previous (timed out) command. + */ + c->bufstart = c->bufend; } c->TimedOut = 0; } _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"