mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
qemu: Fix media eject with qemu-0.12.*
In qemu-0.12.* "device '...' is locked" message was changed to "Device ..." so libvirt was no longer detecting this as an error.
This commit is contained in:
parent
6c8f24751e
commit
e586f57487
@ -63,6 +63,7 @@ sigpipe
|
|||||||
snprintf
|
snprintf
|
||||||
socket
|
socket
|
||||||
stpcpy
|
stpcpy
|
||||||
|
strcasestr
|
||||||
strchrnul
|
strchrnul
|
||||||
strndup
|
strndup
|
||||||
strerror
|
strerror
|
||||||
|
@ -934,7 +934,7 @@ int qemuMonitorTextEjectMedia(qemuMonitorPtr mon,
|
|||||||
/* If the command failed qemu prints:
|
/* If the command failed qemu prints:
|
||||||
* device not found, device is locked ...
|
* device not found, device is locked ...
|
||||||
* No message is printed on success it seems */
|
* No message is printed on success it seems */
|
||||||
if (strstr(reply, "device ")) {
|
if (strcasestr(reply, "device ")) {
|
||||||
qemuReportError(VIR_ERR_OPERATION_FAILED,
|
qemuReportError(VIR_ERR_OPERATION_FAILED,
|
||||||
_("could not eject media on %s: %s"), devname, reply);
|
_("could not eject media on %s: %s"), devname, reply);
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
|
Loading…
Reference in New Issue
Block a user