[libvirt] [PATCHv5 04/28] storage: file: Tolerate NULL src when uninitializing the backend
Eric Blake
eblake at redhat.com
Tue Jul 8 01:44:04 UTC 2014
On 07/04/2014 05:29 AM, Peter Krempa wrote:
> Allow de-init of null storage sources.
> ---
> src/storage/storage_driver.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
ACK
> diff --git a/src/storage/storage_driver.c b/src/storage/storage_driver.c
> index 8c0c5d6..ae86c69 100644
> --- a/src/storage/storage_driver.c
> +++ b/src/storage/storage_driver.c
> @@ -2540,7 +2540,7 @@ int storageRegister(void)
> static bool
> virStorageFileIsInitialized(virStorageSourcePtr src)
> {
> - return !!src->drv;
> + return src && src->drv;
> }
>
>
--
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: 604 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20140707/03a4f263/attachment-0001.sig>
More information about the libvir-list
mailing list