summaryrefslogtreecommitdiff
path: root/RtAudio.cpp
diff options
context:
space:
mode:
authorStephen Sinclair <sinclair@music.mcgill.ca>2013-10-11 01:49:55 +0200
committerStephen Sinclair <sinclair@music.mcgill.ca>2013-10-11 01:49:55 +0200
commitf467eb4624f0ebd6ed1889e9ff5ce8955b92a551 (patch)
treef0e950a4b7e88f1b52e98ca6e35e8233e6021069 /RtAudio.cpp
parent0876bbd0bad22677b23342c828bc36c3babbed4e (diff)
parent8f2275b4cf067760f574e00c41697107930e1912 (diff)
Merge 4.0.1 into releases
Diffstat (limited to 'RtAudio.cpp')
-rw-r--r--RtAudio.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/RtAudio.cpp b/RtAudio.cpp
index bc3a42b..376319c 100644
--- a/RtAudio.cpp
+++ b/RtAudio.cpp
@@ -5906,7 +5906,9 @@ extern "C" void *alsaCallbackHandler( void *ptr )
#ifdef SCHED_RR
// Set a higher scheduler priority (P.J. Leonard)
struct sched_param param;
- param.sched_priority = 39; // Is this the best number?
+ int min = sched_get_priority_min( SCHED_RR );
+ int max = sched_get_priority_max( SCHED_RR );
+ param.sched_priority = min + ( max - min ) / 2; // Is this the best number?
sched_setscheduler( 0, SCHED_RR, &param );
#endif
@@ -6832,7 +6834,7 @@ extern "C" void *ossCallbackHandler( void *ptr )
// message printing.
void RtApi :: error( RtError::Type type )
{
- if ( type == RtError::RtError::WARNING && showWarnings_ == true )
+ if ( type == RtError::WARNING && showWarnings_ == true )
std::cerr << '\n' << errorText_ << "\n\n";
else
throw( RtError( errorText_, type ) );