mirror of https://github.com/xemu-project/xemu.git
QemuOpts: repurpose qemu_opts_print to replace print_option_parameters
Currently this function is not used anywhere. In later patches, it will replace print_option_parameters. To avoid print info changes, change qemu_opts_print from fprintf stderr to printf, and remove last printf. Signed-off-by: Chunyan Liu <cyliu@suse.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
5e89db7641
commit
e67905426b
|
@ -156,7 +156,7 @@ QDict *qemu_opts_to_qdict(QemuOpts *opts, QDict *qdict);
|
||||||
void qemu_opts_absorb_qdict(QemuOpts *opts, QDict *qdict, Error **errp);
|
void qemu_opts_absorb_qdict(QemuOpts *opts, QDict *qdict, Error **errp);
|
||||||
|
|
||||||
typedef int (*qemu_opts_loopfunc)(QemuOpts *opts, void *opaque);
|
typedef int (*qemu_opts_loopfunc)(QemuOpts *opts, void *opaque);
|
||||||
int qemu_opts_print(QemuOpts *opts, void *dummy);
|
void qemu_opts_print(QemuOpts *opts);
|
||||||
int qemu_opts_foreach(QemuOptsList *list, qemu_opts_loopfunc func, void *opaque,
|
int qemu_opts_foreach(QemuOptsList *list, qemu_opts_loopfunc func, void *opaque,
|
||||||
int abort_on_failure);
|
int abort_on_failure);
|
||||||
|
|
||||||
|
|
|
@ -895,17 +895,15 @@ void qemu_opts_del(QemuOpts *opts)
|
||||||
g_free(opts);
|
g_free(opts);
|
||||||
}
|
}
|
||||||
|
|
||||||
int qemu_opts_print(QemuOpts *opts, void *dummy)
|
void qemu_opts_print(QemuOpts *opts)
|
||||||
{
|
{
|
||||||
QemuOpt *opt;
|
QemuOpt *opt;
|
||||||
|
|
||||||
fprintf(stderr, "%s: %s:", opts->list->name,
|
printf("%s: %s:", opts->list->name,
|
||||||
opts->id ? opts->id : "<noid>");
|
opts->id ? opts->id : "<noid>");
|
||||||
QTAILQ_FOREACH(opt, &opts->head, next) {
|
QTAILQ_FOREACH(opt, &opts->head, next) {
|
||||||
fprintf(stderr, " %s=\"%s\"", opt->name, opt->str);
|
printf(" %s=\"%s\"", opt->name, opt->str);
|
||||||
}
|
}
|
||||||
fprintf(stderr, "\n");
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int opts_do_parse(QemuOpts *opts, const char *params,
|
static int opts_do_parse(QemuOpts *opts, const char *params,
|
||||||
|
|
Loading…
Reference in New Issue