mirror of
https://github.com/obgm/libcoap.git
synced 2026-11-14 12:19:43 +03:00
net.c: correct return value in coap_send_internal()
The interface description of coap_send_internal says that COAP_INVALID_MID is returned in the case of errors. Presently, it, however, returns "(coap_mid_t)bytes_written" in a special case. Accidentally, bytes_written == -1 == COAP_INVALID_MID in this specific case, which is why no problems occur in practice due to this. As a cosmetic fix, this commit changes the return value to COAP_INVALID_MID.
This commit is contained in:
1 parent
cca9c858b9
commit
693a4e2313
1 file changed
+1
-2