Ignore:
Timestamp:
Dec 16, 2009, 6:34:17 AM (12 years ago)
Author:
charles
Message:

(trunk libT) try not to cache file data read in during verification

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/verify.c

    r9671 r9791  
    100100            if( numRead == bytesThisPass )
    101101                SHA1_Update( &sha, buffer, numRead );
     102#ifdef HAVE_POSIX_FADVISE
     103            posix_fadvise( fd, filePos, bytesThisPass, POSIX_FADV_DONTNEED );
     104#endif
     105#ifdef SYS_DARWIN
     106            fcntl( fd, F_NOCACHE, 1 );
     107#endif
    102108        }
    103109
Note: See TracChangeset for help on using the changeset viewer.