summaryrefslogtreecommitdiff
path: root/ext/standard/lcg.c
diff options
context:
space:
mode:
authorZeev Suraski <zeev@php.net>2001-07-28 11:36:37 (GMT)
committerZeev Suraski <zeev@php.net>2001-07-28 11:36:37 (GMT)
commitd87cc976e1156b839fc6d4aa6b473a126802b8e3 (patch)
tree8acb068dd7458e1c8df3a7d8ecb87d065990fdb1 /ext/standard/lcg.c
parentb4f3b9d3ce9f55cf040fb5aa8f201c64646cab43 (diff)
downloadphp-d87cc976e1156b839fc6d4aa6b473a126802b8e3.tar.gz
Redesigned thread safety mechanism - nua nua
Diffstat (limited to 'ext/standard/lcg.c')
-rw-r--r--ext/standard/lcg.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/standard/lcg.c b/ext/standard/lcg.c
index 6f97a03..f0ba907 100644
--- a/ext/standard/lcg.c
+++ b/ext/standard/lcg.c
@@ -50,7 +50,7 @@ double php_combined_lcg(void)
{
php_int32 q;
php_int32 z;
- LCGLS_FETCH();
+ TSRMLS_FETCH();
MODMULT(53668,40014,12211,2147483563L, LCG(s1));
MODMULT(52774,40692,3791, 2147483399L, LCG(s2));
@@ -63,7 +63,7 @@ double php_combined_lcg(void)
return z * 4.656613e-10;
}
-static void lcg_init_globals(LCGLS_D TSRMLS_DC)
+static void lcg_init_globals(php_lcg_globals *lcg_globals_p TSRMLS_DC)
{
LCG(s1) = 1;
#ifdef ZTS
@@ -83,7 +83,7 @@ PHP_MINIT_FUNCTION(lcg)
PHP_RINIT_FUNCTION(lcg)
{
if (!php_lcg_initialized) {
- lcg_init_globals();
+ lcg_init_globals(&lcg_globals TSRMLS_CC);
php_lcg_initialized = 1;
}
return SUCCESS;