projects
/
qemu
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
71b9b0c
)
Fix segv when passing an unknown protocol
author
Anthony Liguori
<aliguori@us.ibm.com>
Fri, 22 May 2009 13:17:55 +0000
(08:17 -0500)
committer
Anthony Liguori
<aliguori@us.ibm.com>
Fri, 22 May 2009 15:50:29 +0000
(10:50 -0500)
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
block.c
patch
|
blob
|
history
diff --git
a/block.c
b/block.c
index
980fbec
..
cbc83b1
100644
(file)
--- 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);