From f9573cffbde6dd807c7237c60a090b3195d6dbec Mon Sep 17 00:00:00 2001 From: Paul Mackerras Date: Mon, 4 May 1998 06:11:50 +0000 Subject: [PATCH] work around se driver bug --- modules/ppp_ahdlc.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/modules/ppp_ahdlc.c b/modules/ppp_ahdlc.c index c1853bb..cfde35d 100644 --- a/modules/ppp_ahdlc.c +++ b/modules/ppp_ahdlc.c @@ -24,7 +24,7 @@ * OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, * OR MODIFICATIONS. * - * $Id: ppp_ahdlc.c,v 1.7 1998/03/24 23:52:35 paulus Exp $ + * $Id: ppp_ahdlc.c,v 1.8 1998/05/04 06:11:50 paulus Exp $ */ /* @@ -395,12 +395,14 @@ stuff_frame(q, mp) goto bomb; /* - * Put in an initial flag for now. We'll remove it later - * if we decide we don't need it. + * Put in an initial flag, unless the serial driver currently has + * packets still to be transmitted in its queue. */ dp = op->b_wptr; - *dp++ = PPP_FLAG; - --olen; + if (qsize(q->q_next) == 0) { + *dp++ = PPP_FLAG; + --olen; + } /* * For LCP packets with code values between 1 and 7 (Conf-Req @@ -512,12 +514,6 @@ stuff_frame(q, mp) *dp++ = PPP_FLAG; op->b_wptr = dp; - /* - * Remove the initial flag, if possible. - */ - if (qsize(q->q_next) > 0) - ++omsg->b_rptr; - /* * Update statistics. */ -- 2.39.2