mirror of
https://github.com/xemu-project/xemu.git
synced 2024-11-27 13:30:52 +00:00
qemu-option: fix parse_option_number().
It works much better when parse_option_number actually returns the number parsed ... Common breakage resulting from this bug is that 'qemu -hda foo.img -cdrom bar.iso' stops working (cdrom isn't there). Cc: Avi Kivity <avi@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
a414c306c0
commit
21c9f4cdc6
@ -193,6 +193,7 @@ static int parse_option_number(const char *name, const char *value, uint64_t *re
|
||||
fprintf(stderr, "Option '%s' needs a number as parameter\n", name);
|
||||
return -1;
|
||||
}
|
||||
*ret = number;
|
||||
} else {
|
||||
fprintf(stderr, "Option '%s' needs a parameter\n", name);
|
||||
return -1;
|
||||
|
Loading…
Reference in New Issue
Block a user