Patchwork [FOR,0.12,4/4] QemuOpts: allow larger option values.

login
register
mail settings
Submitter Gerd Hoffmann
Date Dec. 10, 2009, 10:11 a.m.
Message ID <1260439868-15061-5-git-send-email-kraxel@redhat.com>
Download mbox | patch
Permalink /patch/40795/
State New
Headers show

Comments

Gerd Hoffmann - Dec. 10, 2009, 10:11 a.m.
Use case: loooooooooooooooooong file names for -drive file=...

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 qemu-option.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/qemu-option.c b/qemu-option.c
index b009109..24392fc 100644
--- a/qemu-option.c
+++ b/qemu-option.c
@@ -705,7 +705,7 @@  int qemu_opts_print(QemuOpts *opts, void *dummy)
 
 int qemu_opts_do_parse(QemuOpts *opts, const char *params, const char *firstname)
 {
-    char option[128], value[128];
+    char option[128], value[1024];
     const char *p,*pe,*pc;
 
     for (p = params; *p != '\0'; p++) {
@@ -751,7 +751,7 @@  int qemu_opts_do_parse(QemuOpts *opts, const char *params, const char *firstname
 
 QemuOpts *qemu_opts_parse(QemuOptsList *list, const char *params, const char *firstname)
 {
-    char value[128], *id = NULL;
+    char value[1024], *id = NULL;
     const char *p;
     QemuOpts *opts;