ia64/xen-unstable
changeset 11830:e321f036f603
[XEND] Check for and fail on non-existent floppy-drive file when starting HVM guest.
The qemu device model hangs when a non-existent floppy file is passed
via 'fda' or 'fdb'. The attached patch checks whether the floppy file
exists and raises an error if it does not.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
The qemu device model hangs when a non-existent floppy file is passed
via 'fda' or 'fdb'. The attached patch checks whether the floppy file
exists and raises an error if it does not.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
author | kfraser@localhost.localdomain |
---|---|
date | Sun Oct 15 09:19:26 2006 +0100 (2006-10-15) |
parents | edcd3a25a2bd |
children | 8631433e5195 |
files | tools/python/xen/xend/image.py |
line diff
1.1 --- a/tools/python/xen/xend/image.py Sun Oct 15 09:15:51 2006 +0100 1.2 +++ b/tools/python/xen/xend/image.py Sun Oct 15 09:19:26 2006 +0100 1.3 @@ -312,6 +312,11 @@ class HVMImageHandler(ImageHandler): 1.4 if v: 1.5 ret.append("-%s" % a) 1.6 ret.append("%s" % v) 1.7 + 1.8 + if a in ['fda', 'fdb' ]: 1.9 + if v: 1.10 + if not os.path.isfile(v): 1.11 + raise VmError("Floppy file %s does not exist." % v) 1.12 log.debug("args: %s, val: %s" % (a,v)) 1.13 1.14 # Handle disk/network related options