TonyGao625 / react-native-screen-recorder

11 stars 8 forks source link

App crashes! #1

Open sagar1garg opened 6 years ago

sagar1garg commented 6 years ago

@TonyGao625 App crashes when screen recording permission is granted. Can't find any error. Any plans to add ios support? It will record screen audio as well right?

manikandasankar commented 5 years ago

@TonyGao625 any fix available for this App crash issue? Happening for me also, once started recording.

Error: java.lang.RuntimeException: Failure delivering result ResultInfo{who=null, request=101, result=-1, data=Intent { (has extras) }} to activity {/.MainActivity}: java.lang.RuntimeException: setAudioSource failed. at android.app.ActivityThread.deliverResults(ActivityThread.java:3699) at android.app.ActivityThread.handleSendResult(ActivityThread.java:3742) at android.app.ActivityThread.-wrap16(ActivityThread.java) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1393) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:148) at android.app.ActivityThread.main(ActivityThread.java:5417) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) Caused by: java.lang.RuntimeException: setAudioSource failed. at android.media.MediaRecorder.setAudioSource(Native Method) at com.shinetechchina.react_native_screen_recorder.RecordService.initRecorder(RecordService.java:101) at com.shinetechchina.react_native_screen_recorder.RecordService.startRecord(RecordService.java:75) at com.shinetechchina.react_native_screen_recorder.ScreenRecorderModule.onActivityResult(ScreenRecorderModule.java:130) at com.facebook.react.bridge.ReactContext.onActivityResult(ReactContext.java:253) at com.facebook.react.ReactInstanceManager.onActivityResult(ReactInstanceManager.java:692) at com.facebook.react.ReactActivityDelegate.onActivityResult(ReactActivityDelegate.java:129) at com.facebook.react.ReactActivity.onActivityResult(ReactActivity.java:75) at android.app.Activity.dispatchActivityResult(Activity.java:6428) at android.app.ActivityThread.deliverResults(ActivityThread.java:3695)