make it obvious what ctime it is used for.
This commit is contained in:
parent
ec03fa3be9
commit
4167ec87c5
|
@ -57,7 +57,7 @@
|
||||||
|
|
||||||
#if defined(__NetBSD__)
|
#if defined(__NetBSD__)
|
||||||
__COPYRIGHT("@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.");
|
__COPYRIGHT("@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.");
|
||||||
__RCSID("$NetBSD: misc.c,v 1.27 2010/03/05 16:01:09 agc Exp $");
|
__RCSID("$NetBSD: misc.c,v 1.28 2010/04/02 15:28:16 christos Exp $");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
@ -1248,12 +1248,10 @@ netpgp_log(const char *fmt, ...)
|
||||||
va_list vp;
|
va_list vp;
|
||||||
time_t t;
|
time_t t;
|
||||||
char buf[BUFSIZ * 2];
|
char buf[BUFSIZ * 2];
|
||||||
char *cp;
|
|
||||||
int cc;
|
int cc;
|
||||||
|
|
||||||
(void) time(&t);
|
(void) time(&t);
|
||||||
cp = ctime(&t);
|
cc = snprintf(buf, sizeof(buf), "%.24s: netpgp: ", ctime(&t));
|
||||||
cc = snprintf(buf, sizeof(buf), "%.24s: netpgp: ", cp);
|
|
||||||
va_start(vp, fmt);
|
va_start(vp, fmt);
|
||||||
(void) vsnprintf(&buf[cc], sizeof(buf) - (size_t)cc, fmt, vp);
|
(void) vsnprintf(&buf[cc], sizeof(buf) - (size_t)cc, fmt, vp);
|
||||||
va_end(vp);
|
va_end(vp);
|
||||||
|
|
Loading…
Reference in New Issue