[Top][All Lists]

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

[Qemu-commits] [COMMIT c833ab7] Fix segv when passing an unknown protoco

From: Anthony Liguori
Subject: [Qemu-commits] [COMMIT c833ab7] Fix segv when passing an unknown protocol
Date: Fri, 22 May 2009 15:52:44 -0000

From: Anthony Liguori <address@hidden>

Signed-off-by: Anthony Liguori <address@hidden>

diff --git a/block.c b/block.c
index 980fbec..cbc83b1 100644
--- a/block.c
+++ b/block.c
@@ -306,7 +306,7 @@ static BlockDriver *find_image_format(const char *filename)
     drv = find_protocol(filename);
     /* no need to test disk image formats for vvfat */
-    if (strcmp(drv->format_name, "vvfat") == 0)
+    if (drv && strcmp(drv->format_name, "vvfat") == 0)
         return drv;
     ret = bdrv_file_open(&bs, filename, BDRV_O_RDONLY);

reply via email to

[Prev in Thread] Current Thread [Next in Thread]