From 9c3631f24e496cbeb1235e443ff1fc5014356511 Mon Sep 17 00:00:00 2001 From: Kristen Carlson Accardi Date: Mon, 12 Apr 2010 07:38:51 -0700 Subject: ppp: remove references to magic number We will not support loopback detection. --- gatchat/ppp_cp.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'gatchat/ppp_cp.c') diff --git a/gatchat/ppp_cp.c b/gatchat/ppp_cp.c index 8cbb64f4..6cd36817 100644 --- a/gatchat/ppp_cp.c +++ b/gatchat/ppp_cp.c @@ -583,7 +583,7 @@ static void pppcp_send_echo_reply(struct pppcp_data *data, */ packet->identifier = header->identifier; - /* magic number? */ + /* magic number will always be zero */ ppp_transmit(data->ppp, pppcp_to_ppp_packet(packet), ntohs(packet->length)); @@ -860,6 +860,12 @@ static guint8 pppcp_process_protocol_reject(struct pppcp_data *data, return RXJ_MINUS; } +/* + * For Echo-Request, Echo-Reply, and Discard-Request, we will not + * bother checking the magic number of the packet, because we will + * never send an echo or discard request. We can't reliably detect + * loop back anyway, since we don't negotiate a magic number. + */ static guint8 pppcp_process_echo_request(struct pppcp_data *data, struct pppcp_packet *packet) { -- cgit v1.2.3