diff --git a/src/include/netif/ppp/fsm.h b/src/include/netif/ppp/fsm.h index dbffd93c..139ff7fb 100644 --- a/src/include/netif/ppp/fsm.h +++ b/src/include/netif/ppp/fsm.h @@ -73,7 +73,7 @@ */ typedef struct fsm { ppp_pcb *pcb; /* PPP Interface */ - struct fsm_callbacks *callbacks; /* Callback routines */ + const struct fsm_callbacks *callbacks; /* Callback routines */ char *term_reason; /* Reason for closing protocol */ u8_t seen_ack; /* Have received valid Ack/Nak/Rej to Req */ /* -- This is our only flag, we might use u_int :1 if we have more flags */ diff --git a/src/netif/ppp/ccp.c b/src/netif/ppp/ccp.c index a5785329..860374bc 100644 --- a/src/netif/ppp/ccp.c +++ b/src/netif/ppp/ccp.c @@ -230,7 +230,7 @@ static int ccp_extcode (fsm *, int, int, u_char *, int); static void ccp_rack_timeout (void *); static char *method_name (ccp_options *, ccp_options *); -static fsm_callbacks ccp_callbacks = { +static const fsm_callbacks ccp_callbacks = { ccp_resetci, ccp_cilen, ccp_addci, diff --git a/src/netif/ppp/ecp.c b/src/netif/ppp/ecp.c index dc7e3127..728fb5fb 100644 --- a/src/netif/ppp/ecp.c +++ b/src/netif/ppp/ecp.c @@ -133,7 +133,7 @@ ecp_options ecp_gotoptions[NUM_PPP]; /* what the peer agreed to do */ ecp_options ecp_allowoptions[NUM_PPP]; /* what we'll agree to do */ ecp_options ecp_hisoptions[NUM_PPP]; /* what we agreed to do */ -static fsm_callbacks ecp_callbacks = { +static const fsm_callbacks ecp_callbacks = { NULL, /* ecp_resetci, */ NULL, /* ecp_cilen, */ NULL, /* ecp_addci, */ diff --git a/src/netif/ppp/ipcp.c b/src/netif/ppp/ipcp.c index efb56a12..efe5d708 100644 --- a/src/netif/ppp/ipcp.c +++ b/src/netif/ppp/ipcp.c @@ -121,7 +121,7 @@ static void ipcp_up(fsm *f); /* We're UP */ static void ipcp_down(fsm *f); /* We're DOWN */ static void ipcp_finished(fsm *f); /* Don't need lower layer */ -static fsm_callbacks ipcp_callbacks = { /* IPCP callback routines */ +static const fsm_callbacks ipcp_callbacks = { /* IPCP callback routines */ ipcp_resetci, /* Reset our Configuration Information */ ipcp_cilen, /* Length of our Configuration Information */ ipcp_addci, /* Add our Configuration Information */ diff --git a/src/netif/ppp/ipv6cp.c b/src/netif/ppp/ipv6cp.c index 96142ce0..8fb01ada 100644 --- a/src/netif/ppp/ipv6cp.c +++ b/src/netif/ppp/ipv6cp.c @@ -188,7 +188,7 @@ static void ipv6cp_up(fsm *f); /* We're UP */ static void ipv6cp_down(fsm *f); /* We're DOWN */ static void ipv6cp_finished(fsm *f); /* Don't need lower layer */ -static fsm_callbacks ipv6cp_callbacks = { /* IPV6CP callback routines */ +static const fsm_callbacks ipv6cp_callbacks = { /* IPV6CP callback routines */ ipv6cp_resetci, /* Reset our Configuration Information */ ipv6cp_cilen, /* Length of our Configuration Information */ ipv6cp_addci, /* Add our Configuration Information */ diff --git a/src/netif/ppp/lcp.c b/src/netif/ppp/lcp.c index 03783b05..76cec49e 100644 --- a/src/netif/ppp/lcp.c +++ b/src/netif/ppp/lcp.c @@ -241,7 +241,7 @@ static void LcpSendEchoRequest(fsm *f); static void LcpLinkFailure(fsm *f); static void LcpEchoCheck(fsm *f); -static fsm_callbacks lcp_callbacks = { /* LCP callback routines */ +static const fsm_callbacks lcp_callbacks = { /* LCP callback routines */ lcp_resetci, /* Reset our Configuration Information */ lcp_cilen, /* Length of our Configuration Information */ lcp_addci, /* Add our Configuration Information */ diff --git a/src/netif/ppp/pppoe.c b/src/netif/ppp/pppoe.c index 65dd39df..bf69c680 100644 --- a/src/netif/ppp/pppoe.c +++ b/src/netif/ppp/pppoe.c @@ -106,6 +106,7 @@ #define IFF_PASSIVE IFF_LINK0 /* wait passively for connection */ #endif +/* FIXME: we should probably remove that, this is only used for debug purposes */ #ifndef PPPOE_ERRORSTRING_LEN #define PPPOE_ERRORSTRING_LEN 64 #endif