Changeset 5714
- Timestamp:
- Apr 28, 2008, 1:29:38 PM (14 years ago)
- Location:
- trunk/libtransmission
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libtransmission/session.c
r5700 r5714 386 386 387 387 static void 388 tr_close Impl( void * vh )388 tr_closeAllConnections( void * vh ) 389 389 { 390 390 tr_handle * h = vh; 391 391 tr_torrent * t; 392 392 393 tr_webClose( h->web );394 393 tr_sharedShuttingDown( h->shared ); 395 394 tr_trackerShuttingDown( h ); 396 397 _tr_blocklistFree( h->blocklist );398 h->blocklist = NULL;399 395 400 396 for( t=h->torrentList; t!=NULL; ) { … … 429 425 tr_statsClose( h ); 430 426 431 tr_runInEventThread( h, tr_close Impl, h );427 tr_runInEventThread( h, tr_closeAllConnections, h ); 432 428 while( !h->isClosed && !deadlineReached( deadline ) ) 433 429 tr_wait( 100 ); 430 431 _tr_blocklistFree( h->blocklist ); 432 h->blocklist = NULL; 433 tr_webClose( &h->web ); 434 434 435 435 tr_eventClose( h ); -
trunk/libtransmission/web.c
r5712 r5714 320 320 321 321 void 322 tr_webClose( tr_web * web )322 tr_webClose( tr_web ** web ) 323 323 { 324 324 dbgmsg( "deleting web->timer" ); 325 evtimer_del( &web->timer ); 326 curl_multi_cleanup( web->cm ); 327 tr_free( web ); 325 evtimer_del( &(*web)->timer ); 326 curl_multi_cleanup( (*web)->cm ); 327 tr_free( *web ); 328 *web = NULL; 328 329 } 329 330 -
trunk/libtransmission/web.h
r5700 r5714 19 19 tr_web* tr_webInit( tr_handle * session ); 20 20 21 void tr_webClose( tr_web * );21 void tr_webClose( tr_web ** ); 22 22 23 23 typedef void (tr_web_done_func)( tr_handle * session,
Note: See TracChangeset
for help on using the changeset viewer.