aboutsummaryrefslogtreecommitdiff
path: root/block.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2015-11-12 10:09:14 +0000
committerPeter Maydell <peter.maydell@linaro.org>2015-11-12 10:09:14 +0000
commitc459343b8552e65398a05581f7ff31a068b5b551 (patch)
treee50ac07694ead2bb1b67459054004206b37521fe /block.c
parent7497b8dddcaee5b5f1851434607d0de044012ebe (diff)
parent455b0fde8c38a0794743e2e7c1a40018b7bee9f6 (diff)
Merge remote-tracking branch 'remotes/armbru/tags/pull-error-2015-11-11' into staging
error: More error_setg() usage # gpg: Signature made Wed 11 Nov 2015 17:57:15 GMT using RSA key ID EB918653 # gpg: Good signature from "Markus Armbruster <armbru@redhat.com>" # gpg: aka "Markus Armbruster <armbru@pond.sub.org>" * remotes/armbru/tags/pull-error-2015-11-11: error: More error_setg() usage Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'block.c')
-rw-r--r--block.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/block.c b/block.c
index cffac75016..867520a3fd 100644
--- a/block.c
+++ b/block.c
@@ -1801,8 +1801,7 @@ int bdrv_reopen_prepare(BDRVReopenState *reopen_state, BlockReopenQueue *queue,
ret = bdrv_flush(reopen_state->bs);
if (ret) {
- error_set(errp, ERROR_CLASS_GENERIC_ERROR, "Error (%s) flushing drive",
- strerror(-ret));
+ error_setg_errno(errp, -ret, "Error flushing drive");
goto error;
}