From 583458543c9e56f06245ab0cc993cdaff80a6a8f Mon Sep 17 00:00:00 2001 From: Ed Schouten Date: Fri, 14 Oct 2011 07:24:48 +0000 Subject: [PATCH] Build look(1) with WARNS=6. --- usr.bin/look/Makefile | 2 -- usr.bin/look/look.c | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/usr.bin/look/Makefile b/usr.bin/look/Makefile index a62003922094..dd724a39eec1 100644 --- a/usr.bin/look/Makefile +++ b/usr.bin/look/Makefile @@ -3,6 +3,4 @@ PROG= look -WARNS?= 2 - .include diff --git a/usr.bin/look/look.c b/usr.bin/look/look.c index fb054a406eb6..ac6082e6ff15 100644 --- a/usr.bin/look/look.c +++ b/usr.bin/look/look.c @@ -134,7 +134,7 @@ main(int argc, char *argv[]) do { if ((fd = open(file, O_RDONLY, 0)) < 0 || fstat(fd, &sb)) err(2, "%s", file); - if (sb.st_size > SIZE_T_MAX) + if (sb.st_size > (off_t)SIZE_T_MAX) errx(2, "%s: %s", file, strerror(EFBIG)); if (sb.st_size == 0) { close(fd);