A simple but substantial change: uIP used the htons()/HTONS() macro
functions for converting between host and network byte order. These names are the de facto standard names for this functionality because of the original BSD TCP/IP implementation. But they cause problems for uIP/Contiki: some platforms define these names themselves (Mac OS, most notably), causing compilation problems for Contiki on those platforms. This commit changes all htons to uip_htons instead. Same goes for htonl, ntohs, and ntohl. All-caps versions as well.
This commit is contained in:
parent
5a46c629de
commit
5585d72c86
115 changed files with 675 additions and 675 deletions
|
@ -30,7 +30,7 @@
|
|||
*
|
||||
* Author: Adam Dunkels <adam@sics.se>
|
||||
*
|
||||
* $Id: shell-udpsend.c,v 1.6 2010/05/31 15:22:08 nifi Exp $
|
||||
* $Id: shell-udpsend.c,v 1.7 2010/10/19 18:29:03 adamdunkels Exp $
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
|
@ -95,11 +95,11 @@ PROCESS_THREAD(shell_udpsend_process, ev, data)
|
|||
port = shell_strtolong(next, &nextptr);
|
||||
|
||||
uiplib_ipaddrconv(server, &serveraddr);
|
||||
udpconn = udp_new(&serveraddr, htons(port), NULL);
|
||||
udpconn = udp_new(&serveraddr, uip_htons(port), NULL);
|
||||
|
||||
if(next != nextptr) {
|
||||
local_port = shell_strtolong(nextptr, &nextptr);
|
||||
udp_bind(udpconn, htons(local_port));
|
||||
udp_bind(udpconn, uip_htons(local_port));
|
||||
}
|
||||
running = 1;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue