Message ID | 42d2b629549d8be07d14acb6cdd7d0f853ed1a6e.1670979949.git.nabijaczleweli@nabijaczleweli.xyz (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | Herbert Xu |
Headers | show |
Series | [v2,1/3] parser: fixredir: invalid redirections are run-time, not syntax | expand |
diff --git a/src/input.c b/src/input.c index ec075f5..6b6113e 100644 --- a/src/input.c +++ b/src/input.c @@ -195,7 +195,7 @@ retry: } else #endif - nr = read(parsefile->fd, buf, IBUFSIZ - 1); + nr = read(parsefile->fd, buf, parsefile->fd == 0 ? 1 : IBUFSIZ - 1); if (nr < 0) {