diff --git a/core/net/uip.c b/core/net/uip.c index 274fc51c1..69b57ad29 100644 --- a/core/net/uip.c +++ b/core/net/uip.c @@ -41,7 +41,7 @@ * * This file is part of the uIP TCP/IP stack. * - * $Id: uip.c,v 1.26 2010/05/07 20:45:16 oliverschmidt Exp $ + * $Id: uip.c,v 1.27 2010/05/08 07:23:55 oliverschmidt Exp $ * */ @@ -126,12 +126,14 @@ const struct uip_eth_addr uip_ethaddr = {{UIP_ETHADDR0, struct uip_eth_addr uip_ethaddr = {{0,0,0,0,0,0}}; #endif -#ifndef UIP_CONF_EXTERNAL_BUFFER +#ifdef UIP_CONF_PLAIN_BUFFER +uint8_t uip_buf[UIP_BUFSIZE + 2]; +#else /* UIP_CONF_PLAIN_BUFFER */ static uint32_t uip_buf32[(UIP_BUFSIZE + 3) / 4]; -#endif /* UIP_CONF_EXTERNAL_BUFFER */ uint8_t * const uip_buf = (uint8_t * const)uip_buf32; /* The packet buffer that contains incoming packets. */ +#endif /* UIP_CONF_PLAIN_BUFFER */ void *uip_appdata; /* The uip_appdata pointer points to application data. */ diff --git a/core/net/uip.h b/core/net/uip.h index 3deab20ae..77b591386 100644 --- a/core/net/uip.h +++ b/core/net/uip.h @@ -47,7 +47,7 @@ * * This file is part of the uIP TCP/IP stack. * - * $Id: uip.h,v 1.31 2010/05/05 13:07:45 joxe Exp $ + * $Id: uip.h,v 1.32 2010/05/08 07:23:55 oliverschmidt Exp $ * */ @@ -476,7 +476,11 @@ void uip_reass_over(void); } \endcode */ +#ifdef UIP_CONF_PLAIN_BUFFER +CCIF extern uint8_t uip_buf[UIP_BUFSIZE+2]; +#else /* UIP_CONF_PLAIN_BUFFER */ CCIF extern uint8_t * const uip_buf; +#endif /* UIP_CONF_PLAIN_BUFFER */ /** @} */