From 35c2d74d1aa1600d02292497e016de432232b927 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Tue, 3 Mar 2015 09:51:06 +0100 Subject: [PATCH] Cleanup in read_generic_file --- file_ops.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/file_ops.c b/file_ops.c index 51c0a0ec26..7c49b37d79 100644 --- a/file_ops.c +++ b/file_ops.c @@ -114,8 +114,7 @@ static bool read_generic_file(const char *path, void **buf, ssize_t *len) if (_len < 0) goto error; - if (fseek(file, 0, SEEK_SET) != 0) - goto error; + rewind(file); rom_buf = malloc(_len + 1);