diff options
Diffstat (limited to 'sys-utils/tunelp.c')
-rw-r--r-- | sys-utils/tunelp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys-utils/tunelp.c b/sys-utils/tunelp.c index 4d9038aec..5efd6021c 100644 --- a/sys-utils/tunelp.c +++ b/sys-utils/tunelp.c @@ -264,7 +264,8 @@ int main(int argc, char **argv) if (fd < 0) err(EXIT_FAILURE, "%s", filename); - fstat(fd, &statbuf); + if (fstat(fd, &statbuf)) + err(EXIT_FAILURE, "%s: stat() failed", filename); if (!S_ISCHR(statbuf.st_mode)) { warnx(_("%s not an lp device"), filename); |