Skip to content

Commit

Permalink
MicRecoder break switch condition if AudioRecord is null
Browse files Browse the repository at this point in the history
  • Loading branch information
yrom committed Jan 9, 2018
1 parent 8088810 commit 11e0c8b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/main/java/net/yrom/screenrecorder/MicRecorder.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@

import android.media.AudioFormat;
import android.media.AudioRecord;
import android.media.AudioTimestamp;
import android.media.MediaCodec;
import android.media.MediaFormat;
import android.media.MediaRecorder;
Expand Down Expand Up @@ -177,6 +176,7 @@ public void handleMessage(Message msg) {
if (r == null) {
Log.e(TAG, "create audio record failure");
mCallbackDelegate.onError(MicRecorder.this, new IllegalArgumentException());
break;
} else {
r.startRecording();
mMic = r;
Expand Down

0 comments on commit 11e0c8b

Please sign in to comment.