commit 03fbd659ba5124eefbb6261e94c44625dbca03f3
parent 1e24934687420d59e055dc0425e5749362cac54a
Author: Santtu Lakkala <inz@inz.fi>
Date: Wed, 9 Mar 2022 15:49:13 +0200
Reduce code length by 6 bytes
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ii.c b/ii.c
@@ -655,7 +655,7 @@ read_line(int fd, char *buf, size_t bufsiz)
char c = '\0';
do {
- if (read(fd, &c, sizeof(char)) != sizeof(char))
+ if (read(fd, &c, sizeof(c)) != sizeof(c))
return -1;
buf[i++] = c;
} while (c != '\n' && i < bufsiz);