Patchwork [PULL,3/9] block: mirror_complete(): use error_setg_file_open()

login
register
mail settings
Submitter Luiz Capitulino
Date June 17, 2013, 3:57 p.m.
Message ID <1371484631-29510-4-git-send-email-lcapitulino@redhat.com>
Download mbox | patch
Permalink /patch/251907/
State New
Headers show

Comments

Luiz Capitulino - June 17, 2013, 3:57 p.m.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Acked-by: Kevin Wolf <kwolf@redhat.com>
---
 block/mirror.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/block/mirror.c b/block/mirror.c
index 8b07dec..1ae724f 100644
--- a/block/mirror.c
+++ b/block/mirror.c
@@ -512,7 +512,7 @@  static void mirror_complete(BlockJob *job, Error **errp)
         char backing_filename[PATH_MAX];
         bdrv_get_full_backing_filename(s->target, backing_filename,
                                        sizeof(backing_filename));
-        error_set(errp, QERR_OPEN_FILE_FAILED, backing_filename);
+        error_setg_file_open(errp, -ret, backing_filename);
         return;
     }
     if (!s->synced) {