about summary refs log tree commit diff
path: root/include/common.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/common.h')
-rw-r--r--include/common.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/common.h b/include/common.h
index e8558e24..db102777 100644
--- a/include/common.h
+++ b/include/common.h
@@ -426,7 +426,7 @@ static inline u32 read_timed(s32 fd, void *buf, size_t len, u32 timeout_ms) {
 
     }
 
-    len_read = read(fd, buf + len_read, len - len_read);
+    len_read = read(fd, ((u8 *)buf) + len_read, len - len_read);
     if (!len_read) { return 0; }
     read_total += len_read;