summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/sim.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sim.c b/src/sim.c
index a072c8cc..15b44c36 100644
--- a/src/sim.c
+++ b/src/sim.c
@@ -641,9 +641,9 @@ static gboolean cache_record(const char *path, int current, int record_len,
return FALSE;
if (lseek(fd, (current - 1) * record_len +
- SIM_CACHE_HEADER_SIZE, SEEK_SET) !=
- (off_t) -1)
+ SIM_CACHE_HEADER_SIZE, SEEK_SET) != (off_t) -1)
r = TFR(write(fd, data, record_len));
+
TFR(close(fd));
if (r < record_len) {