[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH 7/9] remote: Avoid coverity[leaked_storage] message.



On 22.01.2013 15:41, John Ferlan wrote:
> Upon successful return of virNetClientStreamEventAddCallback() the
> allocated cbdata field will be freed by virNetClientStreamEventRemoveCallback()
> as cbOpaque using the free function remoteStreamCallbackFree().
> ---
>  src/remote/remote_driver.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c
> index 3555dac..341321b 100644
> --- a/src/remote/remote_driver.c
> +++ b/src/remote/remote_driver.c
> @@ -4816,6 +4816,7 @@ remoteStreamEventAddCallback(virStreamPtr st,
>  
>  cleanup:
>      remoteDriverUnlock(priv);
> +    /* coverity[leaked_storage] - cbdata is not leaked */
>      return ret;
>  }
>  
> 

The cleanup label is useless in the function. But it's already been there.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]