Skip to content
Snippets Groups Projects
Unverified Commit dd1bad25 authored by Martine Lenders's avatar Martine Lenders Committed by GitHub
Browse files

Merge pull request #11071 from kb2ma/nanocoap/fix_server_abort

net/nanocoap: don't abort server on recv error
parents a2c14b33 05195ec4
No related branches found
No related tags found
No related merge requests found
...@@ -133,8 +133,7 @@ int nanocoap_server(sock_udp_ep_t *local, uint8_t *buf, size_t bufsize) ...@@ -133,8 +133,7 @@ int nanocoap_server(sock_udp_ep_t *local, uint8_t *buf, size_t bufsize)
while (1) { while (1) {
res = sock_udp_recv(&sock, buf, bufsize, -1, &remote); res = sock_udp_recv(&sock, buf, bufsize, -1, &remote);
if (res < 0) { if (res < 0) {
DEBUG("error receiving UDP packet\n"); DEBUG("error receiving UDP packet %d\n", (int)res);
return -1;
} }
else if (res > 0) { else if (res > 0) {
coap_pkt_t pkt; coap_pkt_t pkt;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment