pike.git / src / builtin_functions.c

version» Context lines:

pike.git/src/builtin_functions.c:1:   /*   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: builtin_functions.c,v 1.533 2004/03/07 02:05:24 nilsson Exp $ + || $Id: builtin_functions.c,v 1.534 2004/03/30 12:50:56 grubba Exp $   */      #include "global.h" - RCSID("$Id: builtin_functions.c,v 1.533 2004/03/07 02:05:24 nilsson Exp $"); + RCSID("$Id: builtin_functions.c,v 1.534 2004/03/30 12:50:56 grubba Exp $");   #include "interpret.h"   #include "svalue.h"   #include "pike_macros.h"   #include "object.h"   #include "program.h"   #include "array.h"   #include "pike_error.h"   #include "constants.h"   #include "mapping.h"   #include "stralloc.h"
pike.git/src/builtin_functions.c:34:   #include <math.h>   #include <ctype.h>   #include "module_support.h"   #include "module.h"   #include "opcodes.h"   #include "cyclic.h"   #include "signal_handler.h"   #include "security.h"   #include "builtin_functions.h"   #include "bignum.h" - #include "language.h" +    #include "peep.h"   #include "docode.h"   #include "lex.h"   #include "pike_float.h"      #ifdef HAVE_POLL   #ifdef HAVE_POLL_H   #include <poll.h>   #endif /* HAVE_POLL_H */   
pike.git/src/builtin_functions.c:4376: Inside #if defined(HAVE_GMTIME)
     /* Inverse operation of gmtime().    */   static time_t my_timegm(struct tm *target_tm)   {    time_t current_ts = 0;    time_t diff_ts;    struct tm *current_tm;    int loop_cnt = 0;    + #if 0 /* The dst offset is part of tz. */    /* Assume dst is one hour. */    target_tm->tm_hour -= target_tm->tm_isdst; -  + #endif /* 0 */       /* This loop seems stable, and usually converges in two passes.    * The loop counter is for paranoia reasons.    */    while((diff_ts = my_tm_diff(target_tm, current_tm = gmtime(&current_ts)))) {    current_ts += diff_ts;    loop_cnt++;    /* fprintf(stderr, "Loop [%d]: %d, %d\n", loop_cnt, current_ts, diff_ts); */    if (loop_cnt > 20) {    /* Infinite loop? */