diff --git a/src/builtin_functions.c b/src/builtin_functions.c index d08afa5276b5facaac85977420c42339ced0df33..48cbd6f646a54e6397f1b4d964f70bd2c8124fd2 100644 --- a/src/builtin_functions.c +++ b/src/builtin_functions.c @@ -4,7 +4,7 @@ ||| See the files COPYING and DISCLAIMER for more information. \*/ #include "global.h" -RCSID("$Id: builtin_functions.c,v 1.78 1998/03/06 16:28:47 grubba Exp $"); +RCSID("$Id: builtin_functions.c,v 1.79 1998/03/09 23:23:53 grubba Exp $"); #include "interpret.h" #include "svalue.h" #include "pike_macros.h" @@ -663,10 +663,9 @@ void f_exit(INT32 args) void f_time(INT32 args) { pop_n_elems(args); - if(args) - push_int(current_time.tv_sec); - else - push_int((INT32)TIME(0)); + if(!args) + GETTIMEOFDAY(¤t_time); + push_int(current_time.tv_sec); } void f_crypt(INT32 args)