Skip to content
Snippets Groups Projects
Commit 61116d5d authored by Jean Aunis's avatar Jean Aunis
Browse files

resource_endpoints.c: memory leak when providing a 404 response

When handling a send_message request to a non-existing endpoint, the response's
body is overriden and not properly freed.

ASTERISK-29108

Change-Id: Ie1d3d70065f80793445b60f5e4a7eb31b4b9c5c8
parent 56028426
No related branches found
No related tags found
3 merge requests!138Merge branch asterisk-20.3.0 into devel properly,!123Merge asterisk '20.3.0' into devel,!118Draft: manager: AOC-S support for AOCMessage
......@@ -211,6 +211,7 @@ static void send_message(const char *to, const char *from, const char *body, str
if (ast_msg_send(msg, to, from)) {
ast_ari_response_error(response, 404, "Not Found",
"Endpoint not found");
return;
}
response->message = ast_json_null();
......
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