mirror of
https://github.com/obgm/libcoap.git
synced 2026-11-15 04:39:42 +03:00
more fixes for Contiki
This commit is contained in:
1 parent
809eb94cba
commit
ceb3ff90e2
2 files changed
+8
No files matched your search
@@ -10,7 +10,11 @@
|
||||
|
||||
#include <ctype.h>
|
||||
#include <stdio.h>
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#elif HAVE_SYS_UNISTD_H
|
||||
#include <sys/unistd.h>
|
||||
#endif
|
||||
#include <sys/types.h>
|
||||
#ifdef HAVE_SYS_SOCKET_H
|
||||
#include <sys/socket.h>
|
||||
|
||||
@@ -83,7 +83,11 @@ coap_pdu_t *
|
||||
coap_new_pdu() {
|
||||
coap_pdu_t *pdu;
|
||||
|
||||
#ifndef WITH_CONTIKI
|
||||
pdu = coap_pdu_init(0, 0, ntohs(COAP_INVALID_TID), COAP_MAX_PDU_SIZE);
|
||||
#else /* WITH_CONTIKI */
|
||||
pdu = coap_pdu_init(0, 0, uip_ntohs(COAP_INVALID_TID), COAP_MAX_PDU_SIZE);
|
||||
#endif /* WITH_CONTIKI */
|
||||
|
||||
#ifndef NDEBUG
|
||||
if (!pdu)
|
||||
|
||||
Reference in new issue
Block a user