diff options
author | Daniel O'Callaghan <danny@FreeBSD.org> | 1999-01-16 03:50:10 +0000 |
---|---|---|
committer | Daniel O'Callaghan <danny@FreeBSD.org> | 1999-01-16 03:50:10 +0000 |
commit | 7621c7c32ab34eeb6028dec1d958d88857ed4487 (patch) | |
tree | 9dd5c71900959cffe618972b5a134f1dfbd1324b | |
parent | 5e2697357117c7f4cfcfff051f610c24fdaa8a3d (diff) | |
download | src-7621c7c32ab34eeb6028dec1d958d88857ed4487.tar.gz src-7621c7c32ab34eeb6028dec1d958d88857ed4487.zip |
Fix Makefile so it works.
Change date format to yyyy/mm/dd hh:mm:ss
Submitted by: Peter Jeremy <peter.jeremy@alcatel.com.au>
Notes
Notes:
svn path=/head/; revision=42714
-rw-r--r-- | release/picobsd/tinyware/simple_httpd/Makefile | 6 | ||||
-rw-r--r-- | release/picobsd/tinyware/simple_httpd/simple_httpd.c | 12 |
2 files changed, 10 insertions, 8 deletions
diff --git a/release/picobsd/tinyware/simple_httpd/Makefile b/release/picobsd/tinyware/simple_httpd/Makefile index 20b9ed4c3ee2..10ea6df7be54 100644 --- a/release/picobsd/tinyware/simple_httpd/Makefile +++ b/release/picobsd/tinyware/simple_httpd/Makefile @@ -1,7 +1,7 @@ -# $Id$ +# $Id: Makefile,v 1.1 1998/08/31 13:10:25 abial Exp $ # -PROG=simple_httpd. -SRCS= simple_httpd..c +PROG=simple_httpd +SRCS= simple_httpd.c NOMAN=yes .include <bsd.prog.mk> diff --git a/release/picobsd/tinyware/simple_httpd/simple_httpd.c b/release/picobsd/tinyware/simple_httpd/simple_httpd.c index 0a83f6737815..5b02244e4de9 100644 --- a/release/picobsd/tinyware/simple_httpd/simple_httpd.c +++ b/release/picobsd/tinyware/simple_httpd/simple_httpd.c @@ -13,7 +13,7 @@ */ /* - * $Id: simple_httpd.c,v 1.1 1998/08/19 16:24:06 abial Exp $ + * $Id: simple_httpd.c,v 1.1.1.1 1998/08/27 17:38:45 abial Exp $ */ #include <stdio.h> @@ -31,6 +31,7 @@ #include <string.h> #include <signal.h> #include <sys/wait.h> +#define LOGDIR "/var/log" int http_sock, con_sock; int http_port = 80; @@ -129,7 +130,7 @@ traite_req() strcat(logfile,"/"); strcat(logfile,"jhttp.log"); } - else strcpy(logfile,"/usr/adm/jhttpd.log"); + else strcpy(logfile, LOGDIR "/jhttpd.log"); if ( access(logfile,W_OK)) { @@ -349,8 +350,9 @@ char *adate() struct tm *t; time(&now); t = localtime(&now); - sprintf(out, "%02d:%02d:%02d %02d/%02d/%02d", - t->tm_hour, t->tm_min, t->tm_sec, - t->tm_mday, t->tm_mon+1, t->tm_year ); + + sprintf(out, "%4d/%02d/%02d %02d:%02d:%02d", + t->tm_year+1900, t->tm_mon+1, t->tm_mday, + t->tm_hour, t->tm_min, t->tm_sec ); return out; } |