Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sbin/ccdconfig rework error message to never call printf() %...



details:   https://anonhg.NetBSD.org/src/rev/699d03df370a
branches:  trunk
changeset: 938302:699d03df370a
user:      mrg <mrg%NetBSD.org@localhost>
date:      Sun Sep 06 02:34:30 2020 +0000

description:
rework error message to never call printf() %s with NULL.

diffstat:

 sbin/ccdconfig/ccdconfig.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 35e796e8f6a8 -r 699d03df370a sbin/ccdconfig/ccdconfig.c
--- a/sbin/ccdconfig/ccdconfig.c        Sun Sep 06 02:34:02 2020 +0000
+++ b/sbin/ccdconfig/ccdconfig.c        Sun Sep 06 02:34:30 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ccdconfig.c,v 1.56 2014/12/07 10:44:34 mlelstv Exp $   */
+/*     $NetBSD: ccdconfig.c,v 1.57 2020/09/06 02:34:30 mrg Exp $       */
 
 /*-
  * Copyright (c) 1996, 1997 The NetBSD Foundation, Inc.
@@ -33,7 +33,7 @@
 #ifndef lint
 __COPYRIGHT("@(#) Copyright (c) 1996, 1997\
  The NetBSD Foundation, Inc.  All rights reserved.");
-__RCSID("$NetBSD: ccdconfig.c,v 1.56 2014/12/07 10:44:34 mlelstv Exp $");
+__RCSID("$NetBSD: ccdconfig.c,v 1.57 2020/09/06 02:34:30 mrg Exp $");
 #endif
 
 #include <sys/param.h>
@@ -245,7 +245,7 @@
 
                cp = strdup(buf);
                if (cp == NULL) {
-                       warn("%s", cp);
+                       warn("strdup failed");
                        goto error;
                }
 



Home | Main Index | Thread Index | Old Index