Changeset 19 for trunk/src/sh_hash.c
- Timestamp:
- Feb 12, 2006, 10:49:56 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_hash.c
r18 r19 2485 2485 2486 2486 if ( (fileHash != NULL) && (p->theFile.checksum != NULL) && 2487 (strncmp (fileHash, p->theFile.checksum, 50) != 0) &&2487 (strncmp (fileHash, p->theFile.checksum, KEY_LEN) != 0) && 2488 2488 (theFile->check_mask & MODI_CHK) != 0) 2489 2489 { 2490 modi_mask |= MODI_CHK; 2491 change_code[0] = 'C'; 2492 TPT ((0, FIL__, __LINE__, _("mod=<checksum>"))); 2490 if ((theFile->check_mask & MODI_SGROW) == 0) 2491 { 2492 modi_mask |= MODI_CHK; 2493 change_code[0] = 'C'; 2494 TPT ((0, FIL__, __LINE__, _("mod=<checksum>"))); 2495 } 2496 else 2497 { 2498 if (0 != strncmp (&fileHash[KEY_LEN + 1], 2499 p->theFile.checksum, KEY_LEN)) 2500 { 2501 modi_mask |= MODI_CHK; 2502 change_code[0] = 'C'; 2503 TPT ((0, FIL__, __LINE__, _("mod=<checksum>"))); 2504 } 2505 else 2506 { 2507 p->theFile.size = theFile->size; 2508 sl_strlcpy(p->theFile.checksum, fileHash, KEY_LEN+1); 2509 } 2510 } 2493 2511 } 2494 2512 … … 2621 2639 (theFile->check_mask & MODI_SIZ) != 0) 2622 2640 { 2623 if (class == SH_LEVEL_LOGGROW && theFile->size < (off_t) p->theFile.size) 2641 if ((theFile->check_mask & MODI_SGROW) == 0 || 2642 theFile->size < (off_t) p->theFile.size) 2624 2643 { 2625 2644 modi_mask |= MODI_SIZ; 2626 2645 change_code[9] = 'S'; 2627 2646 TPT ((0, FIL__, __LINE__, _("mod=<size>"))); 2628 } 2629 else if (class != SH_LEVEL_LOGGROW) 2630 { 2631 modi_mask |= MODI_SIZ; 2632 change_code[9] = 'S'; 2633 TPT ((0, FIL__, __LINE__, _("mod=<size>"))); 2634 } 2647 } 2635 2648 } 2636 2649 change_code[10] = '\0';
Note:
See TracChangeset
for help on using the changeset viewer.