[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [leafnode-list] [ANNOUNCE:] leafnode-1.9.12



Joerg Dietrich wrote:

> age = mktime( &timearray ) + (strstr( arg, "GMT" ) ? 0 : ltime->tm_gmtoff);
> 
> Compiles and finally does what I intended. Sorry for the hassle.

Would the original line then be

age = mktime( &timearray ) - (strstr( arg, "GMT" ) ? 0 : timezone);

The reason I ask is that I want to have a fallback on old libc's which
don't provide tm_gmtoff; i.e. the code looks at the moment like the
following:

#ifdef HAVE_GMTOFF
    age = mktime( &timearray ) + (strstr( arg, "GMT" ) ? 0 : ltime->tm_gmtoff );
#else
    age = mktime( &timearray ) - (strstr( arg, "GMT" ) ? 0 : timezone);
#endif

(HAVE_GMTOFF is defined by ./configure.)

> Unfortunately I found one more problem: leafnode doesn't compile
> under OSF/1 because it lacks snprintf(3).

Well, in that case we have to include an snprintf() in miscutil.c. It
would be nice to have the BSD sourcecode since it doesn't require the
GPL. Where can I download the source of a BSDish version of the libc?

--Cornelius.

-- 
/* Cornelius Krasel, U Wuerzburg, Dept. of Pharmacology, Versbacher Str. 9 */
/* D-97078 Wuerzburg, Germany   email: phak004@xxxxxxxxxxxxxxxxxxxxxx  SP4 */
/* "Science is the game we play with God to find out what His rules are."  */

-- 
leafnode-list@xxxxxxxxxxxxxxxxxxxxxxxxxxxx -- mailing list for leafnode
To unsubscribe, send mail with "unsubscribe" in the subject to the list