summaryrefslogtreecommitdiff
path: root/ext/standard/crypt.c
diff options
context:
space:
mode:
authorfoobar <sniper@php.net>2004-01-19 03:14:58 +0000
committerfoobar <sniper@php.net>2004-01-19 03:14:58 +0000
commite0782e2519ef2cfeeace3f733f8bd0ce71b38aa6 (patch)
tree7aab5425244f90bc1b15114a484da84bf4c228c2 /ext/standard/crypt.c
parentdce4e4c4b26f14be566e8d254434b21b04db710a (diff)
downloadphp-git-e0782e2519ef2cfeeace3f733f8bd0ce71b38aa6.tar.gz
- Moved php_srand() call into php_rand().
# Makes shuffle() and str_shuffle() to be random without having to # call srand() in scripts. # They don't internally call php_srand() at all and it would be silly # to start adding php_srand() calls all over the place..
Diffstat (limited to 'ext/standard/crypt.c')
-rw-r--r--ext/standard/crypt.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c
index 207e1d8b60..3d7ac50f41 100644
--- a/ext/standard/crypt.c
+++ b/ext/standard/crypt.c
@@ -119,10 +119,6 @@ PHP_FUNCTION(crypt)
char *str, *salt_in = NULL;
int str_len, salt_in_len;
- if (!BG(rand_is_seeded)) {
- php_srand(GENERATE_SEED() TSRMLS_CC);
- }
-
salt[0]=salt[PHP_MAX_SALT_LEN]='\0';
/* This will produce suitable results if people depend on DES-encryption
available (passing always 2-character salt). At least for glibc6.1 */