]> Git Repo - qemu.git/commit - migration/qemu-file-channel.c
migration: Add error_desc for file channel errors
authorYury Kotov <[email protected]>
Mon, 22 Apr 2019 10:34:20 +0000 (13:34 +0300)
committerDr. David Alan Gilbert <[email protected]>
Wed, 14 Aug 2019 16:33:14 +0000 (17:33 +0100)
commit3d661c8ab18ad2013992c622ab307422ace891a2
treed1b1ab46d8d0d3b0d3824655e661a469d5caa62b
parentf28ed74fd116491e31329044d140fde4aa23b2a0
migration: Add error_desc for file channel errors

Currently, there is no information about error if outgoing migration was failed
because of file channel errors.
Example (QMP session):
-> { "execute": "migrate", "arguments": { "uri": "exec:head -c 1" }}
<- { "return": {} }
...
-> { "execute": "query-migrate" }
<- { "return": { "status": "failed" }} // There is not error's description

And even in the QEMU's output there is nothing.

This patch
1) Adds errp for the most of QEMUFileOps
2) Adds qemu_file_get_error_obj/qemu_file_set_error_obj
3) And finally using of qemu_file_get_error_obj in migration.c

And now, the status for the mentioned fail will be:
-> { "execute": "query-migrate" }
<- { "return": { "status": "failed",
                 "error-desc": "Unable to write to command: Broken pipe" }}

Signed-off-by: Yury Kotov <[email protected]>
Message-Id: <20190422103420[email protected]>
Reviewed-by: Dr. David Alan Gilbert <[email protected]>
Signed-off-by: Dr. David Alan Gilbert <[email protected]>
migration/migration.c
migration/qemu-file-channel.c
migration/qemu-file.c
migration/qemu-file.h
migration/savevm.c
This page took 0.023492 seconds and 4 git commands to generate.