mirror of
https://github.com/xdsopl/robot36.git
synced 2026-02-27 08:34:14 +01:00
release audio if initialization fails
This commit is contained in:
parent
879b5244f2
commit
55f2726768
|
|
@ -229,6 +229,8 @@ public class MainActivity extends AppCompatActivity {
|
|||
}
|
||||
startListening();
|
||||
} else {
|
||||
audioRecord.release();
|
||||
audioRecord = null;
|
||||
setStatus(R.string.audio_init_failed);
|
||||
}
|
||||
} catch (IllegalArgumentException e) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue