From 2539acf77b018acd7416a9857a14c466e55cd7e8 Mon Sep 17 00:00:00 2001 From: markm Date: Thu, 7 Sep 1995 21:39:00 +0000 Subject: Major cleanup of eBones code: - Get all functions prototyped or at least defined before use. - Make code compile (Mostly) clean with -Wall set - Start to reduce the degree to which DES aka libdes is built in. - get all functions to the same uniform standard of definition: int foo(a, b) int a; int *b; { : } - fix numerous bugs exposed by above processes. Note - this replaces the previous work which used an unpopular function definition style. --- eBones/krb/log.c | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) (limited to 'eBones/krb/log.c') diff --git a/eBones/krb/log.c b/eBones/krb/log.c index aea6ab9..e33477f 100644 --- a/eBones/krb/log.c +++ b/eBones/krb/log.c @@ -44,12 +44,18 @@ static is_open; * The return value is undefined. */ +__BEGIN_DECLS +char *month_sname __P((int)); +__END_DECLS + + /*VARARGS1 */ -void log(char *format,int a1,int a2,int a3,int a4,int a5,int a6,int a7, - int a8,int a9,int a0) +void log(format,a1,a2,a3,a4,a5,a6,a7,a8,a9,a0) + char *format; + int a1,a2,a3,a4,a5,a6,a7,a8,a9,a0; { - FILE *logfile; - long now; + FILE *logfile, *fopen(); + long time(),now; struct tm *tm; if ((logfile = fopen(log_name,"a")) == NULL) @@ -73,7 +79,9 @@ void log(char *format,int a1,int a2,int a3,int a4,int a5,int a6,int a7, * the logfile defaults to KRBLOG, defined in "krb.h". */ -void set_logfile(char *filename) +void +set_logfile(filename) + char *filename; { log_name = filename; is_open = 0; @@ -86,7 +94,10 @@ void set_logfile(char *filename) * on success. */ -int new_log(long t, char *string) +int +new_log(t,string) + long t; + char *string; { static FILE *logfile; -- cgit v1.1