[net.bugs] UNIX in the Year 2037

slb@bnl.UUCP (Sanford L. Barr at Brookhaven National Labs, L.I.) (02/05/85)

	According to the little blurb of a program someone
wrote on this newsgroup a week or so ago. Our PDP-11/44
running V7 will get up to the year 2037 and then revert
back to 1901.  Has anyone else found some other neat
symptoms on their systems?

				San

Copy of unix time tester follows:
(Type positive or negative integer depending upon how far forward
or backward you wish to go.)

-----CUT HERE-----					-----CUT HERE-----
#include <stdio.h>
#include <time.h>
#define YEAR 31536000  /* only roughly, but who cares */

main()

{
long time(), clock;
float increment;
char * ctime();

	time(&clock);
	fputs(ctime(&clock), stdout);

	while (scanf("%f", &increment) > 0) {
		clock += (long) (increment * YEAR);
		fputs(ctime(&clock), stdout);
	}
}



-- 
                        Sanford L. Barr
           Famous designer of the Write Only Memory.
                       --             --
		..!decvax!philabs!sbcs!bnl!slb