dbeu Tue Mar 13 03:09:37 2001 EDT Modified files: /php4/main reentrancy.c Log: fix bug in php_gmtime_r Index: php4/main/reentrancy.c diff -u php4/main/reentrancy.c:1.25 php4/main/reentrancy.c:1.26 --- php4/main/reentrancy.c:1.25 Sun Feb 25 22:07:31 2001 +++ php4/main/reentrancy.c Tue Mar 13 03:09:37 2001 @@ -205,11 +205,14 @@ local_lock(GMTIME_R); tmp = gmtime(timep); - memcpy(p_tm, tmp, sizeof(struct tm)); + if (tmp) { + memcpy(p_tm, tmp, sizeof(struct tm)); + tmp = p_tm; + } local_unlock(GMTIME_R); - return p_tm; + return tmp; } #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]