A couple of fixes, including one which gives confidence we can submit to Factory finally. OBS-URL: https://build.opensuse.org/request/show/612290 OBS-URL: https://build.opensuse.org/package/show/Virtualization/qemu?expand=0&rev=410
54 lines
1.3 KiB
Diff
54 lines
1.3 KiB
Diff
From cceb1b09c36f71bdb84cd8b3ad20d63335fc1559 Mon Sep 17 00:00:00 2001
|
|
From: Bruce Rogers <brogers@suse.com>
|
|
Date: Fri, 25 May 2018 09:09:28 -0600
|
|
Subject: [PATCH] Revert "replay: check return values of fwrite"
|
|
|
|
This reverts commit 6dc0f5296359ff59c248215a965c8658dea9544b.
|
|
|
|
[BR: BSC#1094406]
|
|
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
|
---
|
|
replay/replay-internal.c | 17 ++---------------
|
|
1 file changed, 2 insertions(+), 15 deletions(-)
|
|
|
|
diff --git a/replay/replay-internal.c b/replay/replay-internal.c
|
|
index b077cb5fd5..8e7474f787 100644
|
|
--- a/replay/replay-internal.c
|
|
+++ b/replay/replay-internal.c
|
|
@@ -24,23 +24,12 @@
|
|
static QemuMutex lock;
|
|
|
|
/* File for replay writing */
|
|
-static bool write_error;
|
|
FILE *replay_file;
|
|
|
|
-static void replay_write_error(void)
|
|
-{
|
|
- if (!write_error) {
|
|
- error_report("replay write error");
|
|
- write_error = true;
|
|
- }
|
|
-}
|
|
-
|
|
void replay_put_byte(uint8_t byte)
|
|
{
|
|
if (replay_file) {
|
|
- if (putc(byte, replay_file) == EOF) {
|
|
- replay_write_error();
|
|
- }
|
|
+ putc(byte, replay_file);
|
|
}
|
|
}
|
|
|
|
@@ -73,9 +62,7 @@ void replay_put_array(const uint8_t *buf, size_t size)
|
|
{
|
|
if (replay_file) {
|
|
replay_put_dword(size);
|
|
- if (fwrite(buf, 1, size, replay_file) != size) {
|
|
- replay_write_error();
|
|
- }
|
|
+ fwrite(buf, 1, size, replay_file);
|
|
}
|
|
}
|
|
|