cvs: php4 /ext/standard crypt.c
| From: | Derick Rethans | Date: | Mon, 08 Jan 2001 21:13:24 +0000 |
| Subject: | cvs: php4 /ext/standard crypt.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-3492@lists.php.net to get a copy of this message | ||
derick Mon Jan 8 13:13:24 2001 EDT
Modified files:
/php4/ext/standard crypt.c
Log:
- Fix for bug #8535 - floating point exception on FreeBSD while initializing
crypt random numbers
Index: php4/ext/standard/crypt.c
diff -u php4/ext/standard/crypt.c:1.33 php4/ext/standard/crypt.c:1.34
--- php4/ext/standard/crypt.c:1.33 Sun Jan 7 09:22:17 2001
+++ php4/ext/standard/crypt.c Mon Jan 8 13:13:24 2001
@@ -17,7 +17,7 @@
| Rasmus Lerdorf <rasmus@lerdorf.on.ca> |
+----------------------------------------------------------------------+
*/
-/* $Id: crypt.c,v 1.33 2001/01/07 17:22:17 derick Exp $ */
+/* $Id: crypt.c,v 1.34 2001/01/08 21:13:24 derick Exp $ */
#include <stdlib.h>
#include "php.h"
@@ -106,7 +106,7 @@
REGISTER_LONG_CONSTANT("CRYPT_BLOWFISH", PHP_BLOWFISH_CRYPT, CONST_CS |
CONST_PERSISTENT);
#if HAVE_SRAND48
- srand48((unsigned int) time(0) * getpid() * (php_combined_lcg() * 10000.0));
+ srand48((long) time(0) * (long) getpid() * (long) (php_combined_lcg() * 10000.0));
#elif HAVE_SRANDOM
srandom((unsigned int) time(0) * getpid() * (php_combined_lcg() * 10000.0));
#else