Xref: utzoo comp.lang.c:35308 comp.unix.programmer:855 comp.unix.questions:28111 Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!wuarchive!julius.cs.uiuc.edu!psuvax1!ukma!dftsrv!tsingle From: tsingle@sunland.gsfc.nasa.gov (Tim Singletary) Newsgroups: comp.lang.c,comp.unix.programmer,comp.unix.questions Subject: need "yy-ddd-hh:mm:ss ==> (time_t) clock" converter Message-ID: Date: 18 Jan 91 17:08:47 GMT Sender: news@dftsrv.gsfc.nasa.gov Distribution: comp Organization: Goddard Space Flight Center, Greenbelt, MD Lines: 19 Help! I need something to convert yy-ddd-hh:mm:ss (i.e. year, day_of_year, hour, minute, second) to a unix-style _number_of_seconds_since_00:00:00_GMT,_Jan._1,_1970_. I tried to use Sun's timelocal() function but couldn't get it to work (it lets you pass both _day_of_year_ and _month,_day_of_month_ with no way to specify which is correct!). Ideally what I'm looking for is source code to a timelocal() function, but any tips or suggestions will be appreciated. Thanks in advance, tim -- Tim Singletary, August Automation Inc., (301) 286-7942 -- NRA extremist, etc.