diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2017-12-20 13:20:47 +0000 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2017-12-20 13:20:48 +0000 |
commit | 200780a3a3ed067dfb2e0d2210b0ed09e748ba26 (patch) | |
tree | 06a391d2220c2ed2ae890ea21bf1080ccaf03c03 /util | |
parent | f1faf2d59c91a8f1f59a0fc6339154efb749b55d (diff) | |
parent | 3e05349de8bd6744d23a26beac9ed6fb2e286f80 (diff) |
Merge remote-tracking branch 'remotes/armbru/tags/pull-cmdline-2017-12-18-v2' into staging
Command line patches for 2017-12-18
# gpg: Signature made Wed 20 Dec 2017 08:11:57 GMT
# gpg: using RSA key 0x3870B400EB918653
# gpg: Good signature from "Markus Armbruster <armbru@redhat.com>"
# gpg: aka "Markus Armbruster <armbru@pond.sub.org>"
# Primary key fingerprint: 354B C8B3 D7EB 2A6B 6867 4E5F 3870 B400 EB91 8653
* remotes/armbru/tags/pull-cmdline-2017-12-18-v2:
option: Drop unused get_param_value(), get_next_param_value()
option: Remove shadowing opt decl from qemu_opt_print()
qemu-options: Belatedly document --watchdog-action inject-nmi
qemu-options: Polish section "Character device options"
qemu-options: Polish section "TPM device options"
qemu-options: Add missing -iscsi Texinfo documentation
qemu-options: Move -iscsi under "Block device options"
qemu-options qemu-doc: Move "Device URL Syntax" to qemu-doc
qemu-options: Fix markup of -netdev l2tpv3
qemu-options: Remove stray colons from output of --help
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'util')
-rw-r--r-- | util/qemu-option.c | 36 |
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) { |