From f0e8ebe0d0b06298df9ad016afca762f383fb3f6 Mon Sep 17 00:00:00 2001 From: Olaf Bergmann Date: Fri, 19 Jun 2020 16:51:55 +0200 Subject: [PATCH] coap-server.c: free allocated uri memory in hnd_delete This fixes CID 1483548. --- examples/coap-server.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/examples/coap-server.c b/examples/coap-server.c index 6f1cabd6..ba15123b 100644 --- a/examples/coap-server.c +++ b/examples/coap-server.c @@ -418,8 +418,8 @@ hnd_delete(coap_context_t *ctx, /* Dynamic resource no longer required - delete it */ coap_delete_resource(ctx, resource); + coap_delete_string(uri_path); response->code = COAP_RESPONSE_CODE(202); - return; } /* @@ -472,7 +472,6 @@ hnd_get(coap_context_t *ctx UNUSED_PARAM, resource_entry->media_type, -1, value.length, value.s); - return; } /*