From 59e0971be42d6d7eeaf345952e19b2be3c2c0b9d Mon Sep 17 00:00:00 2001 From: tholo <> Date: Mon, 28 Oct 1996 16:53:28 +0000 Subject: Deal correctly with time zones --- src/lib/libc/string/strftime.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/lib') diff --git a/src/lib/libc/string/strftime.c b/src/lib/libc/string/strftime.c index c1d1e95ffd..21be6667b4 100644 --- a/src/lib/libc/string/strftime.c +++ b/src/lib/libc/string/strftime.c @@ -32,7 +32,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char *rcsid = "$OpenBSD: strftime.c,v 1.6 1996/08/19 08:34:18 tholo Exp $"; +static char *rcsid = "$OpenBSD: strftime.c,v 1.7 1996/10/28 16:53:28 tholo Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -257,7 +257,8 @@ _fmt(format, t) return(0); continue; case 'Z': - if (t->tm_zone && !_add(t->tm_zone)) + if (tzname[t->tm_isdst ? 1 : 0] && + !_add(tzname[t->tm_isdst ? 1 : 0])) return(0); continue; case '%': -- cgit v1.2.3-55-g6feb