block: mirror_complete(): use error_setg_file_open()
authorLuiz Capitulino <lcapitulino@redhat.com>
Fri, 7 Jun 2013 18:31:46 +0000 (14:31 -0400)
committerLuiz Capitulino <lcapitulino@redhat.com>
Mon, 17 Jun 2013 15:01:14 +0000 (11:01 -0400)
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

index 8b07dec314812c77cc103e7158a6fb9e949d3480..1ae724f70549f2b533c1aeff926e3a7dbccc38f3 100644 (file)
@@ -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) {