From aff9ff83562164a33289610260c081767ae971ae Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 8 Jan 2001 21:13:24 +0000 Subject: [PATCH] - Fix for bug #8535 - floating point exception on FreeBSD while initializing crypt random numbers --- ext/standard/crypt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index aa10020bee5..d4cc55b43cd 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -106,7 +106,7 @@ PHP_MINIT_FUNCTION(crypt) 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