Re: [PATCH v2] rpc: fix memory leak in virNetServerClientNew and virNetServerProgramDispatchCall

30 Sep
2022
30 Sep
'22
3:02 a.m.
On 9/30/22 04:32, Jiang Jiacheng wrote:
I see, maybe we could free dispatcher->arg_filter and dispatcher->ret_filter together in error label like this: error: if (dispatcher) { xdr_free(dispatcher->arg_filter, arg); xdr_free(dispatcher->ret_filter, ret); } and in successful path, we can free them before return.
Yes, this is what I tested just before suggesting it. Michal
1072
Age (days ago)
1072
Last active (days ago)
0 comments
1 participants
participants (1)
-
Michal Prívozník