Changeset 1201 for trunk/mod_cacher/xc_cacher.c
- Timestamp:
- 12/17/2012 02:22:49 PM (5 months ago)
- Files:
-
- 1 modified
-
trunk/mod_cacher/xc_cacher.c (modified) (11 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/mod_cacher/xc_cacher.c
r1199 r1201 411 411 time_t n = XG(request_time) / interval; 412 412 if (*curtime != n) { 413 zend_uint target_slot = n% count;413 zend_uint target_slot = ((zend_uint) n) % count; 414 414 zend_uint slot; 415 415 for (slot = advance_wrapped(*curslot, count); … … 449 449 { 450 450 xc_entry_t *p, **pp; 451 int i, c;451 size_t i, c; 452 452 453 453 for (i = 0, c = cache->hentry->size; i < c; i ++) { … … 517 517 static void xc_gc_expires_var(TSRMLS_D) /* {{{ */ 518 518 { 519 int i, c;519 size_t i, c; 520 520 521 521 if (!xc_var_gc_interval || !xc_var_caches) { … … 736 736 { 737 737 zval* list; 738 int i, c;738 size_t i, c; 739 739 xc_entry_t *e; 740 740 … … 934 934 char *tokbuf; 935 935 size_t path_buffer_len; 936 int size;936 size_t size; 937 937 char tokens[] = { DEFAULT_DIR_SEPARATOR, '\0' }; 938 938 int ret; … … 969 969 if (zend_is_executing(TSRMLS_C)) { 970 970 const char *executing_filename = zend_get_executed_filename(TSRMLS_C); 971 int dirname_len = strlen(executing_filename);971 int dirname_len = (int) strlen(executing_filename); 972 972 size_t filename_len = strlen(filepath); 973 973 … … 1066 1066 1067 1067 compiler->new_entry.entry.name.str.val = xc_expand_url(filepath, compiler->opened_path_buffer TSRMLS_CC); 1068 compiler->new_entry.entry.name.str.len = strlen(compiler->new_entry.entry.name.str.val);1068 compiler->new_entry.entry.name.str.len = (int) strlen(compiler->new_entry.entry.name.str.val); 1069 1069 1070 1070 *entry_checker_data->stored_entry = (xc_entry_php_t *) xc_entry_find_unlocked( … … 1144 1144 else { 1145 1145 #ifdef ZEND_ENGINE_2_3 1146 char *opened_path = php_resolve_path(compiler->filename, compiler->filename_len, PG(include_path) TSRMLS_CC);1146 char *opened_path = php_resolve_path(compiler->filename, (int) compiler->filename_len, PG(include_path) TSRMLS_CC); 1147 1147 if (opened_path) { 1148 1148 strcpy(compiler->opened_path_buffer, opened_path); … … 1182 1182 1183 1183 delta = XG(request_time) - buf.st_mtime; 1184 if (abs( delta) < 2 && !xc_test) {1184 if (abs((int) delta) < 2 && !xc_test) { 1185 1185 return FAILURE; 1186 1186 } … … 1214 1214 ++basename_begin; 1215 1215 1216 basename_hash_value = HASH_STR_L(basename_begin, filename_end - basename_begin);1216 basename_hash_value = HASH_STR_L(basename_begin, (uint) (filename_end - basename_begin)); 1217 1217 } 1218 1218 … … 1254 1254 1255 1255 PHP_MD5Init(&context); 1256 while ((n = php_stream_read(stream, (char *) buf, sizeof(buf))) > 0) {1256 while ((n = php_stream_read(stream, (char *) buf, (int) sizeof(buf))) > 0) { 1257 1257 PHP_MD5Update(&context, buf, n); 1258 1258 }

