1
0
Fork 0

live with wrong system time: allow caching files with mtime in further

git-svn-id: svn://svn.lighttpd.net/xcache/branches/1.2@471 c26eb9a1-5813-0410-bd6c-c2e55f420ca7
1.2
Xuefer 15 years ago
parent 59f78d0c34
commit 3f302fd4d9
  1. 1
      ChangeLog
  2. 4
      xcache.c

@ -1,5 +1,6 @@
1.2.2 2007-?-?
== ChangeLog ==
* live with wrong system time: allow caching files with mtime in further
* bug fix for compatibility with Zend Optimizer and other non-cachable
* #102: segv when var cacher is too small
* #55: segv php tokenizer on certain special situation

@ -718,6 +718,7 @@ static int xc_entry_init_key_php(xc_entry_t *xce, char *filename, char *opened_p
int cacheid;
xc_entry_data_php_t *php;
char *ptr;
time_t delta;
if (!filename || !SG(request_info).path_translated) {
return 0;
@ -768,7 +769,8 @@ not_relative_path:
/* fall */
stat_done:
if (XG(request_time) - pbuf->st_mtime < 2 && !xc_test) {
delta = XG(request_time) - pbuf->st_mtime < 2;
if (abs(delta) < 2 && !xc_test) {
return 0;
}

Loading…
Cancel
Save