diff options
-rw-r--r-- | ioops.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -102,7 +102,7 @@ int read_blob_or_die(const char *file, void *blob, size_t count) int fd, ret; fd = open_or_die(file, O_RDONLY); - ret = read_or_die(fd, blob, len); + ret = read_or_die(fd, blob, count); close(fd); return ret; @@ -113,7 +113,7 @@ int write_blob_or_die(const char *file, const void *blob, size_t count) int fd, ret; fd = open_or_die_m(file, O_WRONLY | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR); - ret = write_or_die(fd, blob, len); + ret = write_or_die(fd, blob, count); fdatasync(fd); close(fd); |