1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-02-03 13:03:50 +00:00

handle tr_torrentClose( NULL ) gracefully.

This commit is contained in:
Charles Kerr 2008-01-16 17:57:13 +00:00
parent 61fc032dc1
commit 5965d8d1ae

View file

@ -994,12 +994,15 @@ closeTorrent( void * vtor )
void
tr_torrentClose( tr_torrent * tor )
{
tr_globalLock( tor->handle );
if( tor != NULL )
{
tr_globalLock( tor->handle );
tr_torrentClearStatusCallback( tor );
tr_runInEventThread( tor->handle, closeTorrent, tor );
tr_torrentClearStatusCallback( tor );
tr_runInEventThread( tor->handle, closeTorrent, tor );
tr_globalUnlock( tor->handle );
tr_globalUnlock( tor->handle );
}
}
/**