[ovs-dev] [PATCH 04/15] jsonrpc: Fix potential memory leak.

Justin Pettit jpettit at nicira.com
Wed Mar 24 23:31:14 UTC 2010


Looks good.

--Justin


On Mar 24, 2010, at 1:18 PM, Ben Pfaff wrote:

> This is unlikely to occur very often in practice, because s->stream
> usually gets stuffed into s->rpc before long, but it is still a good idea
> to fix it.
> ---
> lib/jsonrpc.c |    1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/lib/jsonrpc.c b/lib/jsonrpc.c
> index 5c7dfca..5e05480 100644
> --- a/lib/jsonrpc.c
> +++ b/lib/jsonrpc.c
> @@ -684,6 +684,7 @@ jsonrpc_session_close(struct jsonrpc_session *s)
>     if (s) {
>         jsonrpc_close(s->rpc);
>         reconnect_destroy(s->reconnect);
> +        stream_close(s->stream);
>         free(s);
>     }
> }
> -- 
> 1.6.6.1
> 
> 
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev_openvswitch.org





More information about the dev mailing list