Fix warnings about unreachable code in cubeb

master
Fedor 2019-05-20 09:01:03 +03:00
parent 2113b4eb60
commit 88427f4eeb
2 changed files with 2 additions and 2 deletions

View File

@ -562,7 +562,7 @@ int cubeb_set_log_callback(cubeb_log_level log_level,
void void
cubeb_crash() cubeb_crash()
{ {
abort();
*((volatile int *) NULL) = 0; *((volatile int *) NULL) = 0;
abort();
} }

View File

@ -1443,12 +1443,12 @@ audiounit_set_buffer_size(cubeb_stream * stm, uint32_t new_size_frames, set_buff
buffer_size_changed_callback, buffer_size_changed_callback,
stm); stm);
if (r != noErr) { if (r != noErr) {
return CUBEB_ERROR;
if (set_side == INPUT) { if (set_side == INPUT) {
PRINT_ERROR_CODE("AudioUnitAddPropertyListener/input/kAudioDevicePropertyBufferFrameSize", r); PRINT_ERROR_CODE("AudioUnitAddPropertyListener/input/kAudioDevicePropertyBufferFrameSize", r);
} else { } else {
PRINT_ERROR_CODE("AudioUnitAddPropertyListener/output/kAudioDevicePropertyBufferFrameSize", r); PRINT_ERROR_CODE("AudioUnitAddPropertyListener/output/kAudioDevicePropertyBufferFrameSize", r);
} }
return CUBEB_ERROR;
} }
if (!stm->buffer_size_change_state && count >= 30) { if (!stm->buffer_size_change_state && count >= 30) {