diff --git a/libtransmission/trevent.c b/libtransmission/trevent.c index 60909c87a..8f3637274 100644 --- a/libtransmission/trevent.c +++ b/libtransmission/trevent.c @@ -235,8 +235,8 @@ libeventThreadFunc( void * veh ) event_set_log_callback( logFunc ); /* loop until all the events are done */ - while( !eh->die ) - event_dispatch( ); + event_dispatch( ); + assert( eh->die ); /* shut down the thread */ tr_lockFree( eh->lock );