Source-Changes-HG archive

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

[src/trunk]: src/crypto/dist/kame/racoon correct plogv().



details:   https://anonhg.NetBSD.org/src/rev/e6e12ce2f23f
branches:  trunk
changeset: 526631:e6e12ce2f23f
user:      itojun <itojun%NetBSD.org@localhost>
date:      Tue May 07 08:58:32 2002 +0000

description:
correct plogv().

diffstat:

 crypto/dist/kame/racoon/plog.c |  12 +++---------
 crypto/dist/kame/racoon/plog.h |   4 ++--
 2 files changed, 5 insertions(+), 11 deletions(-)

diffs (61 lines):

diff -r 1f2afe3297ab -r e6e12ce2f23f crypto/dist/kame/racoon/plog.c
--- a/crypto/dist/kame/racoon/plog.c    Tue May 07 08:57:31 2002 +0000
+++ b/crypto/dist/kame/racoon/plog.c    Tue May 07 08:58:32 2002 +0000
@@ -1,4 +1,4 @@
-/*     $KAME: plog.c,v 1.22 2002/04/26 00:00:10 itojun Exp $   */
+/*     $KAME: plog.c,v 1.23 2002/05/07 08:56:19 sakane Exp $   */
 
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -131,23 +131,18 @@
 
 void
 plogv(int pri, const char *func, struct sockaddr *sa,
-       const char *fmt, ...)
+       const char *fmt, va_list ap)
 {
        char *newfmt;
-       va_list ap;
 
        if (pri > loglevel)
                return;
 
        newfmt = plog_common(pri, fmt, func);
 
-       if (f_foreground) {
-               va_start(ap, fmt);
+       if (f_foreground)
                vprintf(newfmt, ap);
-               va_end(ap);
-       }
 
-       va_start(ap, fmt);
        if (logfile)
                log_vaprint(logp, newfmt, ap);
        else {
@@ -156,7 +151,6 @@
                else
                        vsyslog(LOG_ALERT, newfmt, ap);
        }
-       va_end(ap);
 }
 
 void
diff -r 1f2afe3297ab -r e6e12ce2f23f crypto/dist/kame/racoon/plog.h
--- a/crypto/dist/kame/racoon/plog.h    Tue May 07 08:57:31 2002 +0000
+++ b/crypto/dist/kame/racoon/plog.h    Tue May 07 08:58:32 2002 +0000
@@ -1,4 +1,4 @@
-/*     $KAME: plog.h,v 1.9 2002/04/26 00:00:10 itojun Exp $    */
+/*     $KAME: plog.h,v 1.10 2002/05/07 08:56:19 sakane Exp $   */
 
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -62,7 +62,7 @@
 struct sockaddr;
 extern void plog __P((int, const char *, struct sockaddr *, const char *, ...));
 extern void plogv __P((int, const char *, struct sockaddr *,
-       const char *, ...));
+       const char *, va_list));
 extern void plogdump __P((int, void *, size_t));
 extern void ploginit __P((void));
 extern void plogset __P((char *));



Home | Main Index | Thread Index | Old Index