diff options
author | ache <ache@FreeBSD.org> | 1998-05-15 15:06:58 +0000 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 1998-05-15 15:06:58 +0000 |
commit | 9ab1a03565092c91cb96689a923dbd1865fa9bc3 (patch) | |
tree | b13169ff618d6a4a4d760122080537f2de4df0e5 /libexec | |
parent | 1cc49ca9720289ad79a51eb64747d405a1840ceb (diff) | |
download | FreeBSD-src-9ab1a03565092c91cb96689a923dbd1865fa9bc3.zip FreeBSD-src-9ab1a03565092c91cb96689a923dbd1865fa9bc3.tar.gz |
Do TZ= as first thing, since FTP protocol is unable to tell zone offset in
any case.
It makes no difference for anon account (since chroot already makes it GMT),
but if you do mirror with special non-anon login, in old variant
your mirror will be wholy retransmitted twice in the year due to
time zone changes (/etc/localtime plays bad role here)
Diffstat (limited to 'libexec')
-rw-r--r-- | libexec/ftpd/ftpd.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libexec/ftpd/ftpd.c b/libexec/ftpd/ftpd.c index fca0ad9..9e3b40d 100644 --- a/libexec/ftpd/ftpd.c +++ b/libexec/ftpd/ftpd.c @@ -44,7 +44,7 @@ static char copyright[] = static char sccsid[] = "@(#)ftpd.c 8.4 (Berkeley) 4/16/94"; #endif static const char rcsid[] = - "$Id: ftpd.c,v 1.45 1998/02/24 08:45:57 eivind Exp $"; + "$Id: ftpd.c,v 1.46 1998/04/28 03:37:23 dg Exp $"; #endif /* not lint */ /* @@ -273,7 +273,8 @@ main(argc, argv, envp) char *cp, line[LINE_MAX]; FILE *fd; - tzset(); /* in case no timezone database in ~ftp */ + setenv("TZ", "", 1); /* since protocol have no way to tell offset */ + tzset(); #ifdef OLD_SETPROCTITLE /* |