Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sbin/sysctl give err() some reason to avoid:
details: https://anonhg.NetBSD.org/src/rev/c01aca3447e0
branches: trunk
changeset: 325870:c01aca3447e0
user: pooka <pooka%NetBSD.org@localhost>
date: Fri Jan 10 09:38:56 2014 +0000
description:
give err() some reason to avoid:
sysctl.c:2713:5: error: zero-length gnu_printf format string [-Werror=format-zero-length]
diffstat:
sbin/sysctl/sysctl.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diffs (42 lines):
diff -r 731688b6767c -r c01aca3447e0 sbin/sysctl/sysctl.c
--- a/sbin/sysctl/sysctl.c Fri Jan 10 01:43:55 2014 +0000
+++ b/sbin/sysctl/sysctl.c Fri Jan 10 09:38:56 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sysctl.c,v 1.149 2012/12/13 05:27:01 msaitoh Exp $ */
+/* $NetBSD: sysctl.c,v 1.150 2014/01/10 09:38:56 pooka Exp $ */
/*-
* Copyright (c) 2003 The NetBSD Foundation, Inc.
@@ -68,7 +68,7 @@
#if 0
static char sccsid[] = "@(#)sysctl.c 8.1 (Berkeley) 6/6/93";
#else
-__RCSID("$NetBSD: sysctl.c,v 1.149 2012/12/13 05:27:01 msaitoh Exp $");
+__RCSID("$NetBSD: sysctl.c,v 1.150 2014/01/10 09:38:56 pooka Exp $");
#endif
#endif /* not lint */
@@ -2710,12 +2710,12 @@
else
rv = asprintf(&s, "%zu", i);
if (rv == -1)
- err(1, "");
+ err(1, "bitmask_print 1");
free(os);
os = s;
}
if (s == NULL && (s = strdup("")) == NULL)
- err(1, "");
+ err(1, "bitmask_print 2");
return s;
}
@@ -2724,7 +2724,7 @@
{
char *s = strdup(v);
if (s == NULL)
- err(1, "");
+ err(1, "bitmask_scan");
__BITMAP_ZERO(o);
for (s = strtok(s, ","); s; s = strtok(NULL, ",")) {
Home |
Main Index |
Thread Index |
Old Index