Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!nthropy!andy From: andy@nthropy.UUCP (Andy Lowe) Newsgroups: comp.windows.x Subject: Does time go backwards from 10/24/90? Message-ID: <9012132128.AA12775@nth.com> Date: 13 Dec 90 21:28:03 GMT Lines: 34 Posted-Date: Thu, 13 Dec 90 15:28:03 CST To: comp-windows-x@cs.utexas.edu Fellow Server Hackers: Please forgive me if I'm missing something obvious, but... Consider the following fragment from os/4.2bsd/utils.c: long GetTimeInMillis() { struct timeval tp; gettimeofday(&tp, 0); return(tp.tv_sec * 1000) + (tp.tv_usec / 1000); } gettimeofday() returns seconds since 1/1/70 GMT By my calculations, this computation overflowed 32 bits about 7 weeks ago, since tp.tv_sec is a long (at least in my copy of SunOS). (Notably, tp.tv_sec is declared unsigned long in my copy of AIX 3.1, but is signed in my copies of ISC and SCO unix.) Please responsd via e-mail, if you can shed some light on this for me. Thanks, and regards Andy Lowe andy@nth.com