diff --git a/libtransmission/completion.h b/libtransmission/completion.h index cc4fa82b1..bdfec49e3 100644 --- a/libtransmission/completion.h +++ b/libtransmission/completion.h @@ -61,16 +61,6 @@ tr_completion * tr_cpConstruct( tr_completion *, tr_torrent * ); tr_completion * tr_cpDestruct( tr_completion * ); -static inline tr_completion* tr_cpNew( tr_torrent * tor ) -{ - return tr_cpConstruct( tr_new0( tr_completion, 1 ), tor ); -} - -static inline void tr_cpFree( tr_completion * cp ) -{ - tr_free( tr_cpDestruct( cp ) ); -} - /** *** General **/ diff --git a/libtransmission/fdlimit.h b/libtransmission/fdlimit.h index ecb22890a..c2088d7b1 100644 --- a/libtransmission/fdlimit.h +++ b/libtransmission/fdlimit.h @@ -38,7 +38,6 @@ int tr_open_file_for_writing( const char * filename ); void tr_close_file( int fd ); -int64_t tr_lseek( int fd, int64_t offset, int whence ); ssize_t tr_pread(int fd, void *buf, size_t count, off_t offset); ssize_t tr_pwrite(int fd, const void *buf, size_t count, off_t offset); int tr_prefetch(int fd, off_t offset, size_t count); diff --git a/libtransmission/inout.c b/libtransmission/inout.c index 552bb3bac..a7acfb3b8 100644 --- a/libtransmission/inout.c +++ b/libtransmission/inout.c @@ -57,18 +57,6 @@ enum { TR_IO_READ, TR_IO_PREFETCH, TR_IO_WRITE }; -int64_t -tr_lseek( int fd, int64_t offset, int whence ) -{ -#if defined( HAVE_LSEEK64 ) - return lseek64( fd, (off64_t)offset, whence ); -#elif defined( WIN32 ) - return _lseeki64( fd, offset, whence ); -#else - return lseek( fd, (off_t)offset, whence ); -#endif -} - /* returns 0 on success, or an errno on failure */ static int readOrWriteBytes( tr_session * session, diff --git a/libtransmission/verify.c b/libtransmission/verify.c index 82c71a359..16f4b2124 100644 --- a/libtransmission/verify.c +++ b/libtransmission/verify.c @@ -320,31 +320,13 @@ tr_verifyAdd( tr_torrent * tor, } static int -compareVerifyByTorrent( const void * va, - const void * vb ) +compareVerifyByTorrent( const void * va, const void * vb ) { const struct verify_node * a = va; - const tr_torrent * b = vb; - + const tr_torrent * b = vb; return a->torrent - b; } -tr_bool -tr_verifyInProgress( const tr_torrent * tor ) -{ - tr_bool found = FALSE; - tr_lock * lock = getVerifyLock( ); - tr_lockLock( lock ); - - assert( tr_isTorrent( tor ) ); - - found = ( tor == currentNode.torrent ) - || ( tr_list_find( verifyList, tor, compareVerifyByTorrent ) != NULL ); - - tr_lockUnlock( lock ); - return found; -} - void tr_verifyRemove( tr_torrent * tor ) { diff --git a/libtransmission/verify.h b/libtransmission/verify.h index 78775c040..d4eb822d4 100644 --- a/libtransmission/verify.h +++ b/libtransmission/verify.h @@ -29,8 +29,6 @@ void tr_verifyAdd( tr_torrent * tor, void tr_verifyRemove( tr_torrent * tor ); -tr_bool tr_verifyInProgress( const tr_torrent * tor ); - void tr_verifyClose( tr_session * ); /* @} */