From: Jean-Christophe DUBOIS Date: Wed, 2 Sep 2009 22:37:00 +0000 (+0200) Subject: mv from strdup to qemu_strdup in qemu-option.c X-Git-Tag: v0.12.0-rc0~1240 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d4c3fddd1f6ea62e08fc93887e0a07f0787b38f1;p=thirdparty%2Fqemu.git mv from strdup to qemu_strdup in qemu-option.c one place is using strdup() instead of qemu_strdup Fix it Signed-off-by: Jean-Christophe Dubois Signed-off-by: Anthony Liguori --- diff --git a/qemu-option.c b/qemu-option.c index 61141e0bd6c..0473605c143 100644 --- a/qemu-option.c +++ b/qemu-option.c @@ -274,7 +274,7 @@ int set_option_parameter(QEMUOptionParameter *list, const char *name, case OPT_STRING: if (value != NULL) { - list->value.s = strdup(value); + list->value.s = qemu_strdup(value); } else { fprintf(stderr, "Option '%s' needs a parameter\n", name); return -1; @@ -334,12 +334,12 @@ void free_option_parameters(QEMUOptionParameter *list) while (cur && cur->name) { if (cur->type == OPT_STRING) { - free(cur->value.s); + qemu_free(cur->value.s); } cur++; } - free(list); + qemu_free(list); } /*