eliminate a warning

This commit is contained in:
Mitchell Livingston 2010-04-24 16:50:18 +00:00
parent 52bad7b8a0
commit 99084a1190
2 changed files with 7 additions and 8 deletions

View File

@ -981,18 +981,18 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy
return;
}
Torrent * torrent;
if (!(torrent = [[Torrent alloc] initWithMagnetAddress: address location: nil lib: fLib]))
{
[self invalidOpenMagnetAlert: address];
return;
}
//determine download location
NSString * location = nil;
if ([fDefaults boolForKey: @"DownloadLocationConstant"])
location = [[fDefaults stringForKey: @"DownloadFolder"] stringByExpandingTildeInPath];
Torrent * torrent;
if (!(torrent = [[Torrent alloc] initWithMagnetAddress: address location: location lib: fLib]))
{
[self invalidOpenMagnetAlert: address];
return;
}
//change the location if the group calls for it (this has to wait until after the torrent is created)
if ([[GroupsController groups] usesCustomDownloadLocationForIndex: [torrent groupValue]])
{

View File

@ -102,7 +102,6 @@ int trashDataFile(const char * filename)
return self;
}
#warning need location (and use it)?
- (id) initWithMagnetAddress: (NSString *) address location: (NSString *) location lib: (tr_session *) lib
{
self = [self initWithPath: nil hash: nil torrentStruct: nil magnetAddress: address