提交 bc0f737d 编写于 作者: R Rolf Eike Beer 提交者: Daniel P. Berrange

Fix error messages when parsing USB devices in QEMU

A number of the error messages raised when parsing USB devices
refered to PCI devices by mistake

* src/qemu/qemu_conf.c: s/PCI/USB/ in qemuParseCommandLineUSB()
上级 06973f70
......@@ -5017,7 +5017,7 @@ qemuParseCommandLineUSB(const char *val)
if (!STRPREFIX(val, "host:")) {
qemuReportError(VIR_ERR_INTERNAL_ERROR,
_("unknown PCI device syntax '%s'"), val);
_("unknown USB device syntax '%s'"), val);
VIR_FREE(def);
goto cleanup;
}
......@@ -5033,21 +5033,21 @@ qemuParseCommandLineUSB(const char *val)
start = end + 1;
if (virStrToLong_i(start, NULL, 16, &second) < 0) {
qemuReportError(VIR_ERR_INTERNAL_ERROR,
_("cannot extract PCI device product '%s'"), val);
_("cannot extract USB device product '%s'"), val);
VIR_FREE(def);
goto cleanup;
}
} else {
if (virStrToLong_i(start, &end, 10, &first) < 0 || !end || *end != '.') {
qemuReportError(VIR_ERR_INTERNAL_ERROR,
_("cannot extract PCI device bus '%s'"), val);
_("cannot extract USB device bus '%s'"), val);
VIR_FREE(def);
goto cleanup;
}
start = end + 1;
if (virStrToLong_i(start, NULL, 10, &second) < 0) {
qemuReportError(VIR_ERR_INTERNAL_ERROR,
_("cannot extract PCI device address '%s'"), val);
_("cannot extract USB device address '%s'"), val);
VIR_FREE(def);
goto cleanup;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册