Source-Changes-HG archive

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

[src/trunk]: src sweep of errx/warnx, remove unnecessary trailing \n



details:   https://anonhg.NetBSD.org/src/rev/91677f108679
branches:  trunk
changeset: 534206:91677f108679
user:      grant <grant%NetBSD.org@localhost>
date:      Sat Jul 20 08:36:17 2002 +0000

description:
sweep of errx/warnx, remove unnecessary trailing \n

diffstat:

 crypto/dist/heimdal/appl/kauth/kauth.c                 |   8 ++--
 crypto/dist/heimdal/appl/kauth/rkinit.c                |  10 +++---
 crypto/dist/heimdal/appl/kx/krb4.c                     |   4 +-
 crypto/dist/heimdal/appl/otp/otp.c                     |   4 +-
 crypto/dist/heimdal/kadmin/kadm_conn.c                 |   4 +-
 crypto/dist/kame/libipsec/test-policy.c                |  30 +++++++++---------
 crypto/dist/kame/racoon/eaytest.c                      |   4 +-
 crypto/dist/krb4/admin/ext_srvtab.c                    |   4 +-
 crypto/dist/krb4/admin/kdb_util.c                      |   4 +-
 crypto/dist/krb4/admin/kstash.c                        |   4 +-
 crypto/dist/krb4/appl/bsd/kcmd.c                       |   4 +-
 crypto/dist/krb4/appl/bsd/login.c                      |   6 +-
 crypto/dist/krb4/appl/kauth/kauth.c                    |   8 ++--
 crypto/dist/krb4/appl/kauth/rkinit.c                   |  10 +++---
 crypto/dist/krb4/appl/kx/krb4.c                        |   4 +-
 crypto/dist/krb4/appl/otp/otp.c                        |   4 +-
 crypto/dist/krb4/kadmin/ksrvutil.c                     |   4 +-
 crypto/dist/krb4/kadmin/ksrvutil_get.c                 |   6 +-
 crypto/dist/krb4/slave/kprop.c                         |   4 +-
 distrib/cdrom/macppc_installboot/macppc_installboot.c  |   2 +-
 games/fortune/fortune/fortune.c                        |   6 +-
 games/trek/damage.c                                    |   6 +-
 lib/libusbhid/usage.c                                  |  10 +++---
 libexec/ld.aout_so/arch/ns32k/md.c                     |   4 +-
 libexec/ld.aout_so/rtld.c                              |  10 +++---
 regress/lib/libc/clone/clonetest.c                     |  12 +++---
 regress/lib/libc/string/swabcheck.c                    |   4 +-
 regress/sys/arch/i386/ldt/testldt.c                    |   8 ++--
 regress/sys/kern/getcwd/getcwd.c                       |   4 +-
 regress/sys/kern/sysvmsg/msgtest.c                     |   4 +-
 regress/sys/kern/sysvsem/semtest.c                     |   4 +-
 regress/sys/kern/sysvshm/shmtest.c                     |   4 +-
 sbin/fsck/preen.c                                      |  10 +++---
 sbin/fsdb/fsdb.c                                       |  14 ++++----
 sbin/fsdb/fsdbutil.c                                   |   8 ++--
 sbin/ifconfig/ifconfig.c                               |   6 +-
 sbin/mount_portal/examples/fing.c                      |   2 +-
 sbin/mount_portal/mount_portal.c                       |   6 +-
 sbin/route/route.c                                     |   6 +-
 sbin/scsictl/scsictl.c                                 |  10 +++---
 sys/arch/amiga/stand/bootblock/aout2bb/aout2bb.c       |  10 +++---
 sys/arch/amiga/stand/bootblock/elf2bb/elf2bb.c         |  16 ++++----
 sys/arch/atari/stand/installboot/installboot.c         |   4 +-
 sys/arch/hp700/stand/mkboot/mkboot.c                   |   4 +-
 sys/arch/i386/stand/genprom/genprom.c                  |   4 +-
 sys/arch/i386/stand/installboot/installboot.c          |   6 +-
 sys/arch/pmax/stand/smallnet/setnetimage/setnetimage.c |   8 ++--
 usr.sbin/pkg_install/add/perform.c                     |   6 +-
 usr.sbin/pkg_install/lib/pen.c                         |   4 +-
 usr.sbin/pkg_install/lib/plist.c                       |   4 +-
 50 files changed, 166 insertions(+), 166 deletions(-)

diffs (truncated from 1506 to 300 lines):

diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/heimdal/appl/kauth/kauth.c
--- a/crypto/dist/heimdal/appl/kauth/kauth.c    Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/heimdal/appl/kauth/kauth.c    Sat Jul 20 08:36:17 2002 +0000
@@ -41,7 +41,7 @@
 
 #include "kauth.h"
 
-RCSID("$Id: kauth.c,v 1.1.1.1 2000/06/16 18:31:51 thorpej Exp $");
+RCSID("$Id: kauth.c,v 1.2 2002/07/20 08:36:20 grant Exp $");
 
 krb_principal princ;
 static char srvtab[MaxPathLen];
@@ -155,12 +155,12 @@
        
     code = get_ad_tkt(princ->name, princ->instance, princ->realm, 0);
     if(code) {
-       warnx("get_ad_tkt: %s\n", krb_get_err_text(code));
+       warnx("get_ad_tkt: %s", krb_get_err_text(code));
        return code;
     }
     code = krb_get_cred(princ->name, princ->instance, princ->realm, &c);
     if(code) {
-       warnx("krb_get_cred: %s\n", krb_get_err_text(code));
+       warnx("krb_get_cred: %s", krb_get_err_text(code));
        return code;
     }
 
@@ -179,7 +179,7 @@
                         key,
                         schedule);
     if(code) {
-       warnx("decomp_ticket: %s\n", krb_get_err_text(code));
+       warnx("decomp_ticket: %s", krb_get_err_text(code));
        return code;
     }
     memset(&session, 0, sizeof(session));
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/heimdal/appl/kauth/rkinit.c
--- a/crypto/dist/heimdal/appl/kauth/rkinit.c   Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/heimdal/appl/kauth/rkinit.c   Sat Jul 20 08:36:17 2002 +0000
@@ -33,7 +33,7 @@
 
 #include "kauth.h"
 
-RCSID("$Id: rkinit.c,v 1.1.1.1 2000/06/16 18:31:51 thorpej Exp $");
+RCSID("$Id: rkinit.c,v 1.2 2002/07/20 08:36:20 grant Exp $");
 
 static struct in_addr *
 getalladdrs (char *hostname, unsigned *count)
@@ -46,7 +46,7 @@
 
     hostent = gethostbyname (hostname);
     if (hostent == NULL) {
-       warnx ("gethostbyname '%s' failed: %s\n",
+       warnx ("gethostbyname '%s' failed: %s",
               hostname,
               hstrerror(h_errno));
        return NULL;
@@ -122,7 +122,7 @@
                           getpid(), &msg, &cred, schedule,
                           &thisaddr, &thataddr, KAUTH_VERSION);
     if (status != KSUCCESS) {
-       warnx ("%s: %s\n", hostname, krb_get_err_text(status));
+       warnx ("%s: %s", hostname, krb_get_err_text(status));
        return 1;
     }
     inlen = pack_args (buf, sizeof(buf),
@@ -146,7 +146,7 @@
     }
 
     if (strncmp(ret, "ok", inlen) != 0) {
-       warnx ("error from %s: %.*s\n",
+       warnx ("error from %s: %.*s",
               hostname, inlen, (char *)ret);
        return 1;
     }
@@ -176,7 +176,7 @@
     }
 
     if (strncmp(ret, "ok", inlen) != 0) {
-       warnx ("error from %s: %.*s\n",
+       warnx ("error from %s: %.*s",
               hostname, inlen, (char *)ret);
        return 1;
     }
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/heimdal/appl/kx/krb4.c
--- a/crypto/dist/heimdal/appl/kx/krb4.c        Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/heimdal/appl/kx/krb4.c        Sat Jul 20 08:36:17 2002 +0000
@@ -33,7 +33,7 @@
 
 #include "kx.h"
 
-RCSID("$Id: krb4.c,v 1.1.1.3 2001/02/11 13:51:16 assar Exp $");
+RCSID("$Id: krb4.c,v 1.2 2002/07/20 08:36:20 grant Exp $");
 
 #ifdef KRB4
 
@@ -87,7 +87,7 @@
                           getpid(), &msg, &cred, c->schedule,
                           &kc->thisaddr, &kc->thataddr, KX_VERSION);
     if (status != KSUCCESS) {
-       warnx ("%s: %s\n", host, krb_get_err_text(status));
+       warnx ("%s: %s", host, krb_get_err_text(status));
        return -1;
     }
     memcpy (c->key, cred.session, sizeof(des_cblock));
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/heimdal/appl/otp/otp.c
--- a/crypto/dist/heimdal/appl/otp/otp.c        Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/heimdal/appl/otp/otp.c        Sat Jul 20 08:36:17 2002 +0000
@@ -34,7 +34,7 @@
 #include "otp_locl.h"
 #include <getarg.h>
 
-RCSID("$Id: otp.c,v 1.1.1.3 2001/06/19 22:07:40 assar Exp $");
+RCSID("$Id: otp.c,v 1.2 2002/07/20 08:36:20 grant Exp $");
 
 static int listp;
 static int deletep;
@@ -323,7 +323,7 @@
 
     if(deletep || openp || listp) {
        if(argc != 0)
-           errx(1, "delete, open, and list requires no arguments\n");
+           errx(1, "delete, open, and list requires no arguments");
     } else {
        if(argc != 2)
            errx(1, "setup, and renew requires `num', and `seed'");
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/heimdal/kadmin/kadm_conn.c
--- a/crypto/dist/heimdal/kadmin/kadm_conn.c    Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/heimdal/kadmin/kadm_conn.c    Sat Jul 20 08:36:17 2002 +0000
@@ -36,7 +36,7 @@
 #include <sys/wait.h>
 #endif
 
-RCSID("$Id: kadm_conn.c,v 1.6 2001/06/19 22:39:55 assar Exp $");
+RCSID("$Id: kadm_conn.c,v 1.7 2002/07/20 08:36:20 grant Exp $");
 
 struct kadm_port {
     char *port;
@@ -50,7 +50,7 @@
     struct kadm_port *p;
     p = malloc(sizeof(*p));
     if(p == NULL) {
-       krb5_warnx(context, "failed to allocate %lu bytes\n", 
+       krb5_warnx(context, "failed to allocate %lu bytes", 
                   (unsigned long)sizeof(*p));
        return;
     }
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/kame/libipsec/test-policy.c
--- a/crypto/dist/kame/libipsec/test-policy.c   Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/kame/libipsec/test-policy.c   Sat Jul 20 08:36:17 2002 +0000
@@ -112,9 +112,9 @@
 
                result = test1sub1(&reqs[i]);
                if (result == 0 && reqs[i].result == 1) {
-                       warnx("ERROR: expecting failure.\n");
+                       warnx("ERROR: expecting failure.");
                } else if (result == 1 && reqs[i].result == 0) {
-                       warnx("ERROR: expecting success.\n");
+                       warnx("ERROR: expecting success.");
                }
        }
 
@@ -231,7 +231,7 @@
 
        printf("TEST2\n");
        if (getuid() != 0)
-               errx(1, "root privilege required.\n");
+               errx(1, "root privilege required.");
 
        sp1 = ipsec_set_policy(pol1, strlen(pol1));
        splen1 = ipsec_get_policylen(sp1);
@@ -239,11 +239,11 @@
        splen2 = ipsec_get_policylen(sp2);
 
        if ((so = pfkey_open()) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
 
        printf("spdflush()\n");
        if (pfkey_send_spdflush(so) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        m = pfkey_recv(so);
        free(m);
 
@@ -251,7 +251,7 @@
        if (pfkey_send_spdsetidx(so, (struct sockaddr *)addr, 128,
                                (struct sockaddr *)addr, 128,
                                255, sp1, splen1, 0) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        m = pfkey_recv(so);
        free(m);
        
@@ -259,7 +259,7 @@
        if (pfkey_send_spdupdate(so, (struct sockaddr *)addr, 128,
                                (struct sockaddr *)addr, 128,
                                255, sp2, splen2, 0) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        m = pfkey_recv(so);
        free(m);
 
@@ -270,7 +270,7 @@
        if (pfkey_send_spddelete(so, (struct sockaddr *)addr, 128,
                                (struct sockaddr *)addr, 128,
                                255, sp1, splen1, 0) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        m = pfkey_recv(so);
        free(m);
 
@@ -278,12 +278,12 @@
        if (pfkey_send_spdadd(so, (struct sockaddr *)addr, 128,
                                (struct sockaddr *)addr, 128,
                                255, sp2, splen2, 0) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        spid = test2sub(so);
 
        printf("spdget(%u)\n", spid);
        if (pfkey_send_spdget(so, spid) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        m = pfkey_recv(so);
        free(m);
 
@@ -292,7 +292,7 @@
 
        printf("spddelete2()\n");
        if (pfkey_send_spddelete2(so, spid) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        m = pfkey_recv(so);
        free(m);
 
@@ -300,7 +300,7 @@
        if (pfkey_send_spdadd2(so, (struct sockaddr *)addr, 128,
                                (struct sockaddr *)addr, 128,
                                255, 0, 10, sp2, splen2, 0) < 0)
-               errx(1, "ERROR: %s\n", ipsec_strerror());
+               errx(1, "ERROR: %s", ipsec_strerror());
        spid = test2sub(so);
 
        /* expecting failure */
@@ -308,7 +308,7 @@
        if (pfkey_send_spdupdate(so, (struct sockaddr *)addr, 128,
                                (struct sockaddr *)addr, 128,
                                255, sp2, splen2, 0) == 0) {
-               warnx("ERROR: expecting failure.\n");
+               warnx("ERROR: expecting failure.");
        }
 
        return 0;
@@ -322,9 +322,9 @@
        caddr_t mhp[SADB_EXT_MAX + 1];
 
        if ((msg = pfkey_recv(so)) == NULL)
-               errx(1, "ERROR: pfkey_recv failure.\n");
+               errx(1, "ERROR: pfkey_recv failure.");
        if (pfkey_align(msg, mhp) < 0)
-               errx(1, "ERROR: pfkey_align failure.\n");
+               errx(1, "ERROR: pfkey_align failure.");
 
        return ((struct sadb_x_policy *)mhp[SADB_X_EXT_POLICY])->sadb_x_policy_id;
 }
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/kame/racoon/eaytest.c
--- a/crypto/dist/kame/racoon/eaytest.c Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/kame/racoon/eaytest.c Sat Jul 20 08:36:17 2002 +0000
@@ -204,7 +204,7 @@
 
        asn1dn = eay_str2asn1dn(dnstr, sizeof(dnstr));
        if (asn1dn == NULL || asn1dn->l != asn1dn0.l)
-               errx(1, "asn1dn length mismatched.\n");
+               errx(1, "asn1dn length mismatched.");
 
        /*
         * NOTE: The value pointed by "<==" above is different from the
@@ -212,7 +212,7 @@
         * both of the names are same name.
         */
        if (eay_cmp_asn1dn(&asn1dn0,  asn1dn))
-               errx(1, "asn1dn mismatched.\n");
+               errx(1, "asn1dn mismatched.");
        vfree(asn1dn);
 
        printf("succeed.\n");
diff -r fcea5bf67c71 -r 91677f108679 crypto/dist/krb4/admin/ext_srvtab.c
--- a/crypto/dist/krb4/admin/ext_srvtab.c       Sat Jul 20 07:45:08 2002 +0000
+++ b/crypto/dist/krb4/admin/ext_srvtab.c       Sat Jul 20 08:36:17 2002 +0000
@@ -9,7 +9,7 @@
 
 #include "adm_locl.h"
 
-RCSID("$Id: ext_srvtab.c,v 1.1.1.3 2001/09/17 12:09:42 assar Exp $");
+RCSID("$Id: ext_srvtab.c,v 1.2 2002/07/20 08:36:21 grant Exp $");
 
 static des_cblock master_key;
 static des_cblock session_key;
@@ -39,7 +39,7 @@



Home | Main Index | Thread Index | Old Index