We're also getting this error occasionally in user reports. Here's the full log:
> WebRtcAudioRecordExternal: Potential microphone conflict. Active sessions: 1
> WebRtcAudioRecordExternal: Start recording error: AUDIO_RECORD_START_STATE_MISMATCH. AudioRecord.startRecording failed - incorrect state: 1
> audio_record_jni.cc(line 148): StartRecording failed
From looking at the WebRTC source code, most probably the recording session could not be started because the microphone resource was locked.
Is there a way to detect this issue, so that the call can be aborted with an appropriate error message? Having one-way-audio is very bad UX. The methods in question all seem to get called indirectly by the native code, so there would need to be some kind of error reported. Alternatively, maybe there's some kind of status flag I could poll initially to ensure that microphone access worked?