mirror of
https://github.com/transmission/transmission
synced 2024-12-25 09:13:06 +00:00
#3675 "Not all .part files are removed" - Mac patch
This commit is contained in:
parent
821d315453
commit
3f20d52371
3 changed files with 6 additions and 15 deletions
|
@ -986,7 +986,7 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
[torrent closeRemoveTorrent];
|
[torrent closeRemoveTorrent: NO];
|
||||||
[torrent release];
|
[torrent release];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1054,7 +1054,7 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
[torrent closeRemoveTorrent];
|
[torrent closeRemoveTorrent: NO];
|
||||||
[torrent release];
|
[torrent release];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1457,10 +1457,7 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy
|
||||||
//let's expand all groups that have removed items - they either don't exist anymore, are already expanded, or are collapsed (rpc)
|
//let's expand all groups that have removed items - they either don't exist anymore, are already expanded, or are collapsed (rpc)
|
||||||
[fTableView removeCollapsedGroup: [torrent groupValue]];
|
[fTableView removeCollapsedGroup: [torrent groupValue]];
|
||||||
|
|
||||||
if (deleteData)
|
[torrent closeRemoveTorrent: deleteData];
|
||||||
[torrent trashData];
|
|
||||||
|
|
||||||
[torrent closeRemoveTorrent];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
[torrents release];
|
[torrents release];
|
||||||
|
|
|
@ -64,7 +64,7 @@
|
||||||
|
|
||||||
- (NSDictionary *) history;
|
- (NSDictionary *) history;
|
||||||
|
|
||||||
- (void) closeRemoveTorrent;
|
- (void) closeRemoveTorrent: (BOOL) trashFiles;
|
||||||
|
|
||||||
- (void) changeDownloadFolderBeforeUsing: (NSString *) folder;
|
- (void) changeDownloadFolderBeforeUsing: (NSString *) folder;
|
||||||
|
|
||||||
|
@ -119,7 +119,6 @@
|
||||||
- (void) setPriority: (tr_priority_t) priority;
|
- (void) setPriority: (tr_priority_t) priority;
|
||||||
|
|
||||||
+ (void) trashFile: (NSString *) path;
|
+ (void) trashFile: (NSString *) path;
|
||||||
- (void) trashData;
|
|
||||||
- (void) moveTorrentDataFileTo: (NSString *) folder;
|
- (void) moveTorrentDataFileTo: (NSString *) folder;
|
||||||
- (void) copyTorrentFileTo: (NSString *) path;
|
- (void) copyTorrentFileTo: (NSString *) path;
|
||||||
|
|
||||||
|
|
|
@ -227,7 +227,7 @@ int trashDataFile(const char * filename)
|
||||||
return [self retain];
|
return [self retain];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void) closeRemoveTorrent
|
- (void) closeRemoveTorrent: (BOOL) trashFiles
|
||||||
{
|
{
|
||||||
//allow the file to be indexed by Time Machine
|
//allow the file to be indexed by Time Machine
|
||||||
if (fTimeMachineExclude)
|
if (fTimeMachineExclude)
|
||||||
|
@ -237,7 +237,7 @@ int trashDataFile(const char * filename)
|
||||||
fTimeMachineExclude = nil;
|
fTimeMachineExclude = nil;
|
||||||
}
|
}
|
||||||
|
|
||||||
tr_torrentRemove(fHandle);
|
tr_torrentRemove(fHandle, trashFiles, trashDataFile);
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void) changeDownloadFolderBeforeUsing: (NSString *) folder
|
- (void) changeDownloadFolderBeforeUsing: (NSString *) folder
|
||||||
|
@ -503,11 +503,6 @@ int trashDataFile(const char * filename)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void) trashData
|
|
||||||
{
|
|
||||||
tr_torrentDeleteLocalData(fHandle, trashDataFile);
|
|
||||||
}
|
|
||||||
|
|
||||||
- (void) moveTorrentDataFileTo: (NSString *) folder
|
- (void) moveTorrentDataFileTo: (NSString *) folder
|
||||||
{
|
{
|
||||||
NSString * oldFolder = [self currentDirectory];
|
NSString * oldFolder = [self currentDirectory];
|
||||||
|
|
Loading…
Reference in a new issue