coap_io.h: define flag to indicate that data is available

Non-blocking sockets can set COAP_ENDPOINT_HAS_DATA in flags to tell
coap_read() that this endpoint has new data available for reading.
This commit is contained in:
Olaf Bergmann committed 2016-04-08 15:14:20 +02:00
1 parent 3d7c0d22ea
commit 73aa574f16
1 file changed
+4 -2
+4 -2
View File
@@ -55,8 +55,10 @@ typedef struct coap_endpoint_t {
int flags;
} coap_endpoint_t;
#define COAP_ENDPOINT_NOSEC 0x00
#define COAP_ENDPOINT_DTLS 0x01
#define COAP_ENDPOINT_NOSEC 0x0000
#define COAP_ENDPOINT_DTLS 0x0001
#define COAP_ENDPOINT_HAS_DATA 0x1000
coap_endpoint_t *coap_new_endpoint(const coap_address_t *addr, int flags);