[PATCH] Check character flags in ppp_async ldisc

From: Paul Mackerras
Date: Sat Nov 06 2004 - 01:15:30 EST


Although it was checking the per-character error flags supplied by the
driver for ordinary characters, the ppp_async line discipline code
wasn't checking the flags for special characters, such as the flag and
escape characters (~ and }). This patch adds that check.

Signed-off-by: Paul Mackerras <paulus@xxxxxxxxx>

diff -urN linux-2.5/drivers/net/ppp_async.c pmac-2.5/drivers/net/ppp_async.c
--- linux-2.5/drivers/net/ppp_async.c 2004-10-22 07:00:21.000000000 +1000
+++ pmac-2.5/drivers/net/ppp_async.c 2004-11-06 17:12:05.517208784 +1100
@@ -911,7 +911,9 @@
break;

c = buf[n];
- if (c == PPP_FLAG) {
+ if (flags != NULL && flags[n] != 0) {
+ ap->state |= SC_TOSS;
+ } else if (c == PPP_FLAG) {
process_input_packet(ap);
} else if (c == PPP_ESCAPE) {
ap->state |= SC_ESCAPE;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/