aboutsummaryrefslogtreecommitdiff
path: root/util/qemu-option.c
diff options
context:
space:
mode:
Diffstat (limited to 'util/qemu-option.c')
-rw-r--r--util/qemu-option.c36
1 files changed, 1 insertions, 35 deletions
diff --git a/util/qemu-option.c b/util/qemu-option.c
index 9b1dc8093b..553d3dc552 100644
--- a/util/qemu-option.c
+++ b/util/qemu-option.c
@@ -91,40 +91,6 @@ const char *get_opt_value(char *buf, int buf_size, const char *p)
return p;
}
-int get_next_param_value(char *buf, int buf_size,
- const char *tag, const char **pstr)
-{
- const char *p;
- char option[128];
-
- p = *pstr;
- for(;;) {
- p = get_opt_name(option, sizeof(option), p, '=');
- if (*p != '=')
- break;
- p++;
- if (!strcmp(tag, option)) {
- *pstr = get_opt_value(buf, buf_size, p);
- if (**pstr == ',') {
- (*pstr)++;
- }
- return strlen(buf);
- } else {
- p = get_opt_value(NULL, 0, p);
- }
- if (*p != ',')
- break;
- p++;
- }
- return 0;
-}
-
-int get_param_value(char *buf, int buf_size,
- const char *tag, const char *str)
-{
- return get_next_param_value(buf, buf_size, tag, &str);
-}
-
static void parse_option_bool(const char *name, const char *value, bool *ret,
Error **errp)
{
@@ -766,7 +732,7 @@ void qemu_opts_print(QemuOpts *opts, const char *separator)
}
for (; desc && desc->name; desc++) {
const char *value;
- QemuOpt *opt = qemu_opt_find(opts, desc->name);
+ opt = qemu_opt_find(opts, desc->name);
value = opt ? opt->str : desc->def_value_str;
if (!value) {