[libvirt] [PATCH] sanlock: Avoid freeing uninitialized value

Eric Blake eblake at redhat.com
Wed Sep 3 12:02:33 UTC 2014


On 09/03/2014 05:26 AM, Jiri Denemark wrote:
> https://bugzilla.redhat.com/show_bug.cgi?id=1136788
> Signed-off-by: Jiri Denemark <jdenemar at redhat.com>
> ---
>  src/locking/lock_driver_sanlock.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

ACK

> 
> diff --git a/src/locking/lock_driver_sanlock.c b/src/locking/lock_driver_sanlock.c
> index aade437..aa6b8fb 100644
> --- a/src/locking/lock_driver_sanlock.c
> +++ b/src/locking/lock_driver_sanlock.c
> @@ -885,7 +885,7 @@ static int virLockManagerSanlockAcquire(virLockManagerPtr lock,
>                                          int *fd)
>  {
>      virLockManagerSanlockPrivatePtr priv = lock->privateData;
> -    struct sanlk_options *opt;
> +    struct sanlk_options *opt = NULL;
>      struct sanlk_resource **res_args;
>      int res_count;
>      bool res_free = false;
> 

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 539 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20140903/5e69f22a/attachment-0001.sig>


More information about the libvir-list mailing list