9ae3a8
From 28c5321911bde483484eb95d0bef2e8e65a3593b Mon Sep 17 00:00:00 2001
9ae3a8
From: Dr. David Alan Gilbert (git) <dgilbert@redhat.com>
9ae3a8
Date: Mon, 10 Mar 2014 17:41:44 +0100
9ae3a8
Subject: [PATCH 16/16] qemu_file: Fix mismerge of "use fwrite() correctly"
9ae3a8
9ae3a8
RH-Author: Dr. David Alan Gilbert (git) <dgilbert@redhat.com>
9ae3a8
Message-id: <1394473304-7190-3-git-send-email-dgilbert@redhat.com>
9ae3a8
Patchwork-id: 58074
9ae3a8
O-Subject: [RHEL-7.0 qemu-kvm PATCH v2 2/2] qemu_file: Fix mismerge of "use fwrite() correctly"
9ae3a8
Bugzilla: 1005103
9ae3a8
RH-Acked-by: Juan Quintela <quintela@redhat.com>
9ae3a8
RH-Acked-by: Eric Blake <eblake@redhat.com>
9ae3a8
RH-Acked-by: Amit Shah <amit.shah@redhat.com>
9ae3a8
9ae3a8
From: Markus Armbruster <armbru@redhat.com>
9ae3a8
9ae3a8
Reviewers accepted v2 of the patch, but what got committed was v1,
9ae3a8
with the R-bys for v2.  This is the v1->v2 followup fix.
9ae3a8
9ae3a8
[Amit:
9ae3a8
 This fixes commit aded6539d983280212e08d09f14157b1cb4d58cc
9ae3a8
]
9ae3a8
9ae3a8
Signed-off-by: Markus Armbruster <armbru@redhat.com>
9ae3a8
Reviewed-by: Eric Blake <eblake@redhat.com>
9ae3a8
Reviewed-by: Amit Shah <amit.shah@redhat.com>
9ae3a8
Signed-off-by: Amit Shah <amit.shah@redhat.com>
9ae3a8
Signed-off-by: Juan Quintela <quintela@redhat.com>
9ae3a8
(cherry picked from commit ac4df4e608e84da135eacecd7bba7c6e9e9a63b7)
9ae3a8
9ae3a8
Conflicts:
9ae3a8
	qemu-file.c
9ae3a8
was still in savevm.c
9ae3a8
---
9ae3a8
 savevm.c | 2 +-
9ae3a8
 1 file changed, 1 insertion(+), 1 deletion(-)
9ae3a8
9ae3a8
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
9ae3a8
---
9ae3a8
 savevm.c |    2 +-
9ae3a8
 1 files changed, 1 insertions(+), 1 deletions(-)
9ae3a8
9ae3a8
diff --git a/savevm.c b/savevm.c
9ae3a8
index 94121a2..4d92a7b 100644
9ae3a8
--- a/savevm.c
9ae3a8
+++ b/savevm.c
9ae3a8
@@ -216,7 +216,7 @@ static int stdio_put_buffer(void *opaque, const uint8_t *buf, int64_t pos, int s
9ae3a8
     res = fwrite(buf, 1, size, s->stdio_file);
9ae3a8
 
9ae3a8
     if (res != size) {
9ae3a8
-        return -EIO;	/* fake errno value */
9ae3a8
+        return -errno;
9ae3a8
     }
9ae3a8
     return res;
9ae3a8
 }
9ae3a8
-- 
9ae3a8
1.7.1
9ae3a8