Changeset 279
- Timestamp:
- 10/26/06 21:31:03 (2 years ago)
- Files:
-
- eaccelerator/trunk/ChangeLog (modified) (1 diff)
- eaccelerator/trunk/cache.c (modified) (2 diffs)
- eaccelerator/trunk/eaccelerator.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
eaccelerator/trunk/ChangeLog
r278 r279 1 2006-10-26 Bart Vanbrabant <bart.vanbrabant at zoeloelip.be> 2 3 * Fix encoding and decoding of eA and php versions. Only three numbers 4 versions were encoded, this way file cache isn't removed when using 5 svn snapshots or rc releases. 6 1 7 2006-10-19 Hans Rakers <hans at parse dot nl> 2 8 3 * Replaced short php opening tags in control.php4 * Fixed typo in NEWS file5 * Fix for ticket #170 (handling of multi-dim globals by the optimizer)9 * Replaced short php opening tags in control.php 10 * Fixed typo in NEWS file 11 * Fix for ticket #170 (handling of multi-dim globals by the optimizer) 6 12 7 13 2006-10-10 Bart Vanbrabant <bart.vanbrabant at zoeloelip.be> eaccelerator/trunk/cache.c
r276 r279 269 269 ea_file_header hdr; 270 270 EACCELERATOR_FLOCK(f, LOCK_EX); 271 strncpy(hdr.magic, EA_MAGIC, 8); 272 hdr.eaccelerator_version = binary_eaccelerator_version; 273 hdr.zend_version = binary_zend_version; 274 hdr.php_version = binary_php_version; 271 init_header(&hdr); 275 272 hdr.size = q->size; 276 273 hdr.mtime = q->ttl; … … 388 385 389 386 EACCELERATOR_FLOCK(f, LOCK_SH); 390 if (read(f, &hdr, sizeof(hdr)) != sizeof(hdr) || strncmp(hdr.magic, EA_MAGIC, 8) != 0 || 391 hdr.eaccelerator_version != binary_eaccelerator_version || hdr.zend_version != binary_zend_version 392 || hdr.php_version != binary_php_version) { 387 if (read(f, &hdr, sizeof(hdr)) != sizeof(hdr) || check_header(&hdr)) { 393 388 EACCELERATOR_FLOCK(f, LOCK_UN); 394 389 close(f); eaccelerator/trunk/eaccelerator.h
r273 r279 337 337 typedef struct _ea_file_header { 338 338 char magic[8]; /* "EACCELERATOR" */ 339 int eaccelerator_version ;340 int zend_version ;341 int php_version ;339 int eaccelerator_version[2]; 340 int zend_version[2]; 341 int php_version[2]; 342 342 int size; 343 343 time_t mtime; 344 344 unsigned int crc32; 345 345 } ea_file_header; 346 347 int check_header(ea_file_header *hdr); 348 void init_header(ea_file_header *hdr); 346 349 347 350 typedef struct {