2001-12-03
2001-12-03 15:46:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>
-
b508dca622c01ead53eb7e2b331f8d97c83e9814
(7 lines)
(+4/-3)
[
Show
| Annotate
]
Branch: b508dca622c01ead53eb7e2b331f8d97c83e9814
Fix the sign for tm_gmtoff. Fixes [bug 2584 (#2584)] some more.
Rev: src/builtin_functions.c:1.267
5:
\*/
/**/
#include "global.h"
- RCSID("$Id: builtin_functions.c,v 1.266 2001/12/03 14:19:55 grubba Exp $");
+ RCSID("$Id: builtin_functions.c,v 1.267 2001/12/03 15:46:53 grubba Exp $");
#include "interpret.h"
#include "svalue.h"
#include "pike_macros.h"
2945: Inside #if defined(HAVE_LOCALTIME) and #if defined(STRUCT_TM_HAS_GMTOFF)
#else
#ifdef STRUCT_TM_HAS_GMTOFF
push_string(make_shared_string("timezone"));
- push_int(tm->tm_gmtoff);
+ push_int(-tm->tm_gmtoff);
f_aggregate_mapping(20);
#else
f_aggregate_mapping(18);
3007: Inside #if defined(HAVE_MKTIME) and #if STRUCT_TM_HAS_GMTOFF
#if STRUCT_TM_HAS_GMTOFF
if((args > 7) && (sp[7-args].subtype == NUMBER_NUMBER))
{
- date.tm_gmtoff=sp[7-args].u.integer;
+ date.tm_gmtoff=-sp[7-args].u.integer;
}else{
time_t tmp = 0;
date.tm_gmtoff=localtime(&tmp)->tm_gmtoff;