src/net.c: coap_delete_node() not removing node from context->sendqueue
src/net.c: coap_delete_node() not removing node from context->sendqueue

When coap_wait_ack() is called, it sets node->session with a bumped
reference counter and does a coap_insert_node(&context->sendqueue, node).
[I cannot find anywhere else where node->session gets set]

If coap_delte_node(node) is called, and node-session is set, it previously only
did a coap_session_release(node->session).

Then when coap_write() is called, it does a coap_retransmit() on all the
context->sendqueue entries, one or more of which could now be a deleted
node.....

The node is now removed if appropriate from context->sendqueue by
coap_delete_node().

authmillenon/libcoap,authmillenon/libcoap,authmillenon/libcoap