forked from Imagelibrary/lwip
Revert "ppp: fix compiling with CCP_SUPPORT=1 but MPPE_SUPPORT=0"
This reverts commit 6e7ea92d56.
We better forbid building configurations that does not make sense instead
of bloating the code with more ifdef. Here building CCP support without
adding any compressor support serve no real use case.
This commit is contained in:
@@ -246,7 +246,6 @@ static const fsm_callbacks ccp_callbacks = {
|
||||
* Do we want / did we get any compression?
|
||||
*/
|
||||
static int ccp_anycompress(ccp_options *opt) {
|
||||
LWIP_UNUSED_ARG(opt);
|
||||
return (0
|
||||
#if DEFLATE_SUPPORT
|
||||
|| (opt)->deflate
|
||||
@@ -744,7 +743,6 @@ static void ccp_resetci(fsm *f) {
|
||||
static int ccp_cilen(fsm *f) {
|
||||
ppp_pcb *pcb = f->pcb;
|
||||
ccp_options *go = &pcb->ccp_gotoptions;
|
||||
LWIP_UNUSED_ARG(go);
|
||||
|
||||
return 0
|
||||
#if BSDCOMPRESS_SUPPORT
|
||||
@@ -840,8 +838,6 @@ static int ccp_ackci(fsm *f, u_char *p, int len) {
|
||||
#if BSDCOMPRESS_SUPPORT || PREDICTOR_SUPPORT
|
||||
u_char *p0 = p;
|
||||
#endif /* BSDCOMPRESS_SUPPORT || PREDICTOR_SUPPORT */
|
||||
LWIP_UNUSED_ARG(p);
|
||||
LWIP_UNUSED_ARG(go);
|
||||
|
||||
#if MPPE_SUPPORT
|
||||
if (go->mppe) {
|
||||
@@ -1026,7 +1022,6 @@ static int ccp_rejci(fsm *f, u_char *p, int len) {
|
||||
ppp_pcb *pcb = f->pcb;
|
||||
ccp_options *go = &pcb->ccp_gotoptions;
|
||||
ccp_options try_; /* options to request next time */
|
||||
LWIP_UNUSED_ARG(p);
|
||||
|
||||
try_ = *go;
|
||||
|
||||
@@ -1122,7 +1117,6 @@ static int ccp_reqci(fsm *f, u_char *p, int *lenp, int dont_nak) {
|
||||
u8_t rej_for_ci_mppe = 1; /* Are we rejecting based on a bad/missing */
|
||||
/* CI_MPPE, or due to other options? */
|
||||
#endif /* MPPE_SUPPORT */
|
||||
LWIP_UNUSED_ARG(ao);
|
||||
|
||||
ret = CONFACK;
|
||||
retp = p0 = p;
|
||||
|
||||
@@ -840,9 +840,7 @@ void ppp_input(ppp_pcb *pcb, struct pbuf *pb) {
|
||||
#endif /* MPPE_SUPPORT */
|
||||
|
||||
if (protocol == PPP_COMP) {
|
||||
#if MPPE_SUPPORT
|
||||
u8_t *pl;
|
||||
#endif
|
||||
|
||||
switch (pcb->ccp_receive_method) {
|
||||
#if MPPE_SUPPORT
|
||||
@@ -857,7 +855,6 @@ void ppp_input(ppp_pcb *pcb, struct pbuf *pb) {
|
||||
goto drop; /* Cannot really happen, we only negotiate what we are able to do */
|
||||
}
|
||||
|
||||
#if MPPE_SUPPORT
|
||||
/* Assume no PFC */
|
||||
if (pb->len < 2) {
|
||||
goto drop;
|
||||
@@ -872,7 +869,6 @@ void ppp_input(ppp_pcb *pcb, struct pbuf *pb) {
|
||||
protocol = (pl[0] << 8) | pl[1];
|
||||
pbuf_remove_header(pb, 2);
|
||||
}
|
||||
#endif /* MPPE_SUPPORT */
|
||||
}
|
||||
#endif /* CCP_SUPPORT */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user