cvs: php-src(PHP_4_3) /ext/standard file.c

From: Date: Thu, 24 Jul 2003 15:23:15 +0000
Subject: cvs: php-src(PHP_4_3) /ext/standard file.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-22777@lists.php.net to get a copy of this message
wez Thu Jul 24 11:23:15 2003 EDT Modified files: (Branch: PHP_4_3) /php-src/ext/standard file.c Log: MFH: Fix for #24629 Index: php-src/ext/standard/file.c diff -u php-src/ext/standard/file.c:1.279.2.30 php-src/ext/standard/file.c:1.279.2.31 --- php-src/ext/standard/file.c:1.279.2.30 Fri Jun 27 12:16:46 2003 +++ php-src/ext/standard/file.c Thu Jul 24 11:23:14 2003 @@ -21,7 +21,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: file.c,v 1.279.2.30 2003/06/27 16:16:46 pollita Exp $ */ +/* $Id: file.c,v 1.279.2.31 2003/07/24 15:23:14 wez Exp $ */ /* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */ @@ -808,8 +808,14 @@ /* If seconds is not set to null, build the timeval, else we wait indefinitely */ if (sec != NULL) { convert_to_long_ex(&sec); - tv.tv_sec = Z_LVAL_P(sec); - tv.tv_usec = usec; + + if (usec > 999999) { + tv.tv_sec = Z_LVAL_P(sec) + (usec / 1000000); + tv.tv_usec = usec % 1000000; + } else { + tv.tv_sec = Z_LVAL_P(sec); + tv.tv_usec = usec; + } tv_p = &tv; }

« previous php.cvs (#22777) next »