Timeline: Fix assertion triggered by failure to join a diskthread which self-terminated due to punch-out.
This commit is contained in:
parent
ab88b2d3ec
commit
60059f4005
|
@ -88,7 +88,11 @@ Thread::run_thread ( void *arg )
|
|||
|
||||
((Thread*)td.t)->_running = true;
|
||||
|
||||
return td.entry_point( td.arg );
|
||||
void * r = td.entry_point( td.arg );
|
||||
|
||||
((Thread*)td.t)->_running = false;
|
||||
|
||||
return r;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -137,9 +137,14 @@ Disk_Stream::shutdown ( void )
|
|||
block_processed();
|
||||
usleep( 10 * 1000 );
|
||||
}
|
||||
|
||||
_thread.join();
|
||||
}
|
||||
|
||||
/* thread may have terminated on it's own (due to punch out..), in
|
||||
* any case join to clean up */
|
||||
_thread.join();
|
||||
|
||||
DMESSAGE( "diskthread joined." );
|
||||
|
||||
}
|
||||
|
||||
Track *
|
||||
|
|
|
@ -181,8 +181,6 @@ done:
|
|||
// flush();
|
||||
|
||||
_terminate = false;
|
||||
|
||||
_thread.exit();
|
||||
}
|
||||
|
||||
/** take a single block from the ringbuffers and send it out the
|
||||
|
|
|
@ -247,8 +247,6 @@ again:
|
|||
_recording = false;
|
||||
|
||||
DMESSAGE( "capture thread gone" );
|
||||
|
||||
_thread.exit();
|
||||
}
|
||||
|
||||
|
||||
|
@ -283,20 +281,9 @@ Record_DS::stop ( nframes_t frame )
|
|||
{
|
||||
THREAD_ASSERT( UI );
|
||||
|
||||
if ( ! _recording )
|
||||
{
|
||||
WARNING( "programming error: attempt to stop recording when no recording is being made" );
|
||||
return;
|
||||
}
|
||||
|
||||
_stop_frame = frame;
|
||||
|
||||
// _recording = false;
|
||||
|
||||
|
||||
// detach();
|
||||
|
||||
DMESSAGE( "recording finished" );
|
||||
DMESSAGE( "recording stop scheduled" );
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue