summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRasmus Lerdorf <rasmus@php.net>2007-05-18 11:36:55 +0000
committerRasmus Lerdorf <rasmus@php.net>2007-05-18 11:36:55 +0000
commit7e5f0a8380ca26bf7950873aab733c0816d83d07 (patch)
treee5e1d6769d5e04e86e3c7cc458be40eed294fda4
parentffd09c0961ce3256d68dd61e230ba8484e73e36e (diff)
downloadphp-git-7e5f0a8380ca26bf7950873aab733c0816d83d07.tar.gz
Get rid of a stray time() syscall in tsrm and clean up lcg rinit
-rw-r--r--NEWS1
-rw-r--r--TSRM/tsrm_virtual_cwd.c3
-rw-r--r--ext/standard/php_lcg.h1
3 files changed, 3 insertions, 2 deletions
diff --git a/NEWS b/NEWS
index 24fc07ada7..9c802525c0 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,7 @@
PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
?? ??? 2007, PHP 5.2.3
+- Optimized out a couple of per-request syscalls (Rasmus)
- Upgraded SQLite 3 to version 3.3.16 (Ilia)
- Added PDO::FETCH_KEY_PAIR mode that will fetch a 2 column result set into
an associated array. (Ilia)
diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c
index ccb7ea553c..a7d1d59722 100644
--- a/TSRM/tsrm_virtual_cwd.c
+++ b/TSRM/tsrm_virtual_cwd.c
@@ -31,6 +31,7 @@
#include "tsrm_virtual_cwd.h"
#include "tsrm_strtok_r.h"
+#include "SAPI.h"
#ifdef TSRM_WIN32
#include <io.h>
@@ -518,7 +519,7 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
}
if (use_cache) {
- t = CWDG(realpath_cache_ttl)?time(NULL):0;
+ t = CWDG(realpath_cache_ttl)?sapi_get_request_time(TSRMLS_C):0;
if ((bucket = realpath_cache_find(path, path_length, t TSRMLS_CC)) != NULL) {
int len = bucket->realpath_len;
diff --git a/ext/standard/php_lcg.h b/ext/standard/php_lcg.h
index b036cbce00..e78414ff13 100644
--- a/ext/standard/php_lcg.h
+++ b/ext/standard/php_lcg.h
@@ -33,7 +33,6 @@ PHPAPI double php_combined_lcg(TSRMLS_D);
PHP_FUNCTION(lcg_value);
PHP_MINIT_FUNCTION(lcg);
-PHP_RINIT_FUNCTION(lcg);
#ifdef ZTS
#define LCG(v) TSRMG(lcg_globals_id, php_lcg_globals *, v)