-
Notifications
You must be signed in to change notification settings - Fork 161
Open
Labels
Description
Description:
When enabling screen sharing, the session starts successfully. However, as soon as the user taps anywhere on the screen (button press or general touch), the app crashes with an IndexOutOfBoundsException.
This seems related to [issue #710](#710), but in my case the crash is reproducible on any touch interaction while screen sharing is active.
Steps to Reproduce:
- Start an OpenTok session in a React Native app.
- Enable screen sharing (
videoSource: 'screen'). - Tap on any button or touch anywhere on the screen.
- App crashes immediately.
Expected Behavior:
The app should continue running while interacting with the UI during screen sharing.
Actual Behavior:
The app crashes with an IndexOutOfBoundsException.
Error Log:
From logcat:
java.lang.IndexOutOfBoundsException: Index 1 out of bounds for length 0
at jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64)
at jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266)
at java.util.ArrayList.get(ArrayList.java:434)
at android.view.ViewGroup.getAndVerifyPreorderedView(ViewGroup.java:4019)
...
at com.opentokreactnative.OTScreenCapturer$1.run(OTScreenCapturer.java:52)
at android.os.Handler.handleCallback(Handler.java:995)
at android.os.Handler.dispatchMessage(Handler.java:103)
at android.os.Looper.loop(Looper.java:363)
Full log excerpt attached from reproduction .
Environment:
opentok-react-nativeversion: 2.30.2- React Native version: 0.79.4
- Android version: Android 16
- Device: Samsung S25
Notes:
- The crash only happens when screen sharing is enabled.
- Without screen sharing, UI interactions work fine.
- This may be related to how
OTScreenCapturerinteracts with the view hierarchy during touches.
Reactions are currently unavailable