Hi,
in file dlp.c in line 239 the following was inserted:
/* Seems like year comes back as all zeros if the date is "empty"
* (but other fields can vary). And mktime() chokes on 1900 B.C.
* (result of 0 minus 1900), returning -1, which the higher level
* code can't deal with (passes it straight on to utime(), which
* simply leaves the file's timestamp "as-is").
*
* So, since year 0 appears to mean "no date", we'll return an odd
* number that works out to precisely one day before the start of
* the Palm's clock (thus little chance of being run into by any
* Palm-based time stamp).
*/
if (data[0] == 0 && data[1] == 0)
return (time_t) 0x83D8FE00; /* Dec 31, 1903 00:00:00 GMT */
While the year 1903 is surely a cool idea using a negative value causes "some"
unnecessary problems - at least for the MS VC++ 6.0 c-runtime. For example the
function gmtime() begins like this:
struct tm * __cdecl gmtime (const time_t *timp)
{
long caltim = *timp; /* calendar time to convert */
[...]
if ( caltim < 0L )
return(NULL);
After all this leads to the effect that the change in dlp.c simply doesn't work.
Therefore I'd vote to rather returning 0 meaning Jan 1, 1970 00:00:00 GMT.
Oliver Schmidt
______________________________________________________________________________
Ferienklick.de - 225 Reisekataloge auf einen Blick!
Direkt zu Ihrem Traumurlaub: http://ferienklick.de/?PP=2-0-100-105-0
_______________________________________________
Pilot-unix mailing list
[EMAIL PROTECTED]
http://hcirisc.cs.binghamton.edu/mailman/listinfo/pilot-unix