Module Name: src
Committed By: joerg
Date: Wed Mar 31 21:55:23 UTC 2010
Modified Files:
src/usr.bin/head: head.c
Log Message:
Just ignore the errno of strtoimax, it doesn't provide much value.
To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/usr.bin/head/head.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/usr.bin/head/head.c
diff -u src/usr.bin/head/head.c:1.22 src/usr.bin/head/head.c:1.23
--- src/usr.bin/head/head.c:1.22 Wed Mar 31 21:52:11 2010
+++ src/usr.bin/head/head.c Wed Mar 31 21:55:23 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: head.c,v 1.22 2010/03/31 21:52:11 joerg Exp $ */
+/* $NetBSD: head.c,v 1.23 2010/03/31 21:55:23 joerg Exp $ */
/*
* Copyright (c) 1980, 1987, 1992, 1993
@@ -39,7 +39,7 @@
#if 0
static char sccsid[] = "@(#)head.c 8.2 (Berkeley) 5/4/95";
#else
-__RCSID("$NetBSD: head.c,v 1.22 2010/03/31 21:52:11 joerg Exp $");
+__RCSID("$NetBSD: head.c,v 1.23 2010/03/31 21:55:23 joerg Exp $");
#endif
#endif /* not lint */
@@ -91,7 +91,7 @@
bytecnt = strtoimax(optarg, &ep, 10);
if ((bytecnt == INTMAX_MAX && errno == ERANGE) ||
*ep || bytecnt <= 0)
- err(1, "illegal byte count -- %s", optarg);
+ errx(1, "illegal byte count -- %s", optarg);
break;
case 'n':
@@ -99,7 +99,7 @@
linecnt = strtoimax(optarg, &ep, 10);
if ((linecnt == INTMAX_MAX && errno == ERANGE) ||
*ep || linecnt <= 0)
- err(1, "illegal line count -- %s", optarg);
+ errx(1, "illegal line count -- %s", optarg);
break;
case 'q':