changed uip_buf to a union for 32-bit alignment

This commit is contained in:
joxe 2010-05-24 10:07:34 +00:00
parent 9db7f06368
commit 2d447502d4
4 changed files with 18 additions and 17 deletions

View file

@ -41,7 +41,7 @@
*
* This file is part of the uIP TCP/IP stack.
*
* $Id: uip.c,v 1.27 2010/05/08 07:23:55 oliverschmidt Exp $
* $Id: uip.c,v 1.28 2010/05/24 10:07:34 joxe Exp $
*
*/
@ -126,13 +126,11 @@ const struct uip_eth_addr uip_ethaddr = {{UIP_ETHADDR0,
struct uip_eth_addr uip_ethaddr = {{0,0,0,0,0,0}};
#endif
/* The packet buffer that contains incoming packets. */
#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];
uint8_t * const uip_buf = (uint8_t * const)uip_buf32;
/* The packet buffer that contains
incoming packets. */
uip_buf_t uip_aligned_buf;
#endif /* UIP_CONF_PLAIN_BUFFER */
void *uip_appdata; /* The uip_appdata pointer points to