Message ID | 20240805140840.1606239-3-hadess@hadess.net |
---|---|
State | New |
Headers | show |
Series | None | expand |
diff --git a/tools/isotest.c b/tools/isotest.c index 2cac0e49cc39..0805faa66e47 100644 --- a/tools/isotest.c +++ b/tools/isotest.c @@ -779,6 +779,8 @@ static int read_stream(int fd, ssize_t count) len = read(fd, buf + ret, count - ret); if (len < 0) return -errno; + if (len > SSIZE_MAX - ret) + return -EOVERFLOW; ret += len; usleep(1000);