-
Problem report
-
Resolution: Fixed
-
Minor
-
4.0.9
-
Sprint 53 (Jun 2019), Sprint 54 (Jul 2019)
-
0.5
When mutiple messages are queued to be sent to clients either by service or by asynchronous socket, the message container is not freed after next message is popped from the send queue:
diff --git a/src/libs/zbxipcservice/ipcservice.c b/src/libs/zbxipcservice/ipcservice.c index 5b7cd179fc..bce29b4fd9 100644 --- a/src/libs/zbxipcservice/ipcservice.c +++ b/src/libs/zbxipcservice/ipcservice.c @@ -613,6 +613,7 @@ static void ipc_client_pop_tx_message(zbx_ipc_client_t *client) client->tx_header[ZBX_IPC_MESSAGE_CODE] = message->code; client->tx_header[ZBX_IPC_MESSAGE_SIZE] = message->size; client->tx_data = message->data; + zbx_free(message); } /******************************************************************************
However currently this leak is theoretical, as service uses strictly request/response pattern when communicating with clients and the same pattern is used when async socket is used by external clients to communicate with a service.