From 515d04de1a74e328b1df25e862881ce302a760ac Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Sat, 27 Oct 2007 14:17:51 +0000 Subject: [PATCH] Ticket #395 (ensure file exists when starting) --- libtransmission/torrent.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libtransmission/torrent.c b/libtransmission/torrent.c index 906948a91..fb8702b5b 100644 --- a/libtransmission/torrent.c +++ b/libtransmission/torrent.c @@ -1028,6 +1028,9 @@ tr_torrentStart( tr_torrent * tor ) if( !tor->isRunning ) { + if( !tor->uncheckedPieces ) + tor->uncheckedPieces = tr_bitfieldNew( tor->info.pieceCount ); + tr_fastResumeLoad( tor, tor->uncheckedPieces, tor->destination, FALSE ); tor->isRunning = 1; tr_ioRecheckAdd( tor, checkAndStartCB ); }