Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RTMP throws fatal exception #44

Open
LloydBlv opened this issue Aug 27, 2017 · 10 comments
Open

RTMP throws fatal exception #44

LloydBlv opened this issue Aug 27, 2017 · 10 comments

Comments

@LloydBlv
Copy link

LloydBlv commented Aug 27, 2017

While playing RTMP stream this weird exception happens, And gives no clue about why its happening:

E/ExoPlayerImplInternal: Source error.
net.butterflytv.rtmp_client.RtmpClient$RtmpIOException
at net.butterflytv.rtmp_client.RtmpClient.open(RtmpClient.java:53)
at com.google.android.exoplayer2.ext.rtmp.RtmpDataSource.open(RtmpDataSource.java:57)
at com.google.android.exoplayer2.upstream.DefaultDataSource.open(DefaultDataSource.java:137)
at com.google.android.exoplayer2.source.ExtractorMediaPeriod$ExtractingLoadable.load(ExtractorMediaPeriod.java:692)
at com.google.android.exoplayer2.upstream.Loader$LoadTask.run(Loader.java:315)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)
at java.lang.Thread.run(Thread.java:818)
08-26 22:40:08.186 7769-9587/com.myapp A/libc: Fatal signal 11 (SIGSEGV), code 1, fault addr 0xf88e3c8c in tid 9587 (Loader:Extracto)

Please help!

@mekya
Copy link
Contributor

mekya commented Aug 27, 2017

Please check out the RTMPIOException errorcode

Can I test the rtmp url?

@LloydBlv
Copy link
Author

@mekya Thanks for your response, the url is generated dynamically, so I cant share, I looked at the url you mentioned, Is there anyway to prevent the app from crash and show a proper error message?

@mekya
Copy link
Contributor

mekya commented Aug 30, 2017

Yeah sure, have you tried to catch the RTMPIOException with try-catch block and show an appropriate message?

@ojw28
Copy link

ojw28 commented Sep 4, 2017

The app doesn't crash when this error occurs. It's already caught by ExoPlayer internally, and propagated to the player's event listener (which gives you a handy point where you can show an appropriate error message).

If your app is crashing, it's not directly related to the logging at the top of this thread. You'd need to provide a more complete log or bug report.

@keremkusmezer
Copy link

I have also a similar issue you can find the bug detail in
google/ExoPlayer#3156

Rtmp Client also dies

@mekya
Copy link
Contributor

mekya commented Dec 19, 2017

It is interesting. The thread you mentioned(google/ExoPlayer#3156) has been resolved. You are still having the sampe problem?

@nagendraK6
Copy link

nagendraK6 commented Jan 9, 2018

I am testing antmedia server and getting similar exception. The rtmp url works fine if I run from VLC player or ffplay on mac

I am putting rtmp url like this

rtmp://34.213.233.241:1935/LiveApp/228154535248454858718201

Error code i am receiving -4

@nagendraK6
Copy link

/ExoPlayerImplInternal: Source error.
net.butterflytv.rtmp_client.RtmpClient$RtmpIOException
at net.butterflytv.rtmp_client.RtmpClient.open(RtmpClient.java:53)
at com.google.android.exoplayer2.ext.rtmp.RtmpDataSource.open(RtmpDataSource.java:57)
at com.google.android.exoplayer2.source.ExtractorMediaPeriod$ExtractingLoadable.load(ExtractorMediaPeriod.java:692)
at com.google.android.exoplayer2.upstream.Loader$LoadTask.run(Loader.java:315)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at java.lang.Thread.run(Thread.java:764)

@aktjkt
Copy link

aktjkt commented May 30, 2018

Still Getting the same issue
E/ExoPlayerImplInternal: Source error.
net.butterflytv.rtmp_client.RtmpClient$RtmpIOException
at net.butterflytv.rtmp_client.RtmpClient.open(RtmpClient.java:56)
at com.google.android.exoplayer2.ext.rtmp.RtmpDataSource.open(RtmpDataSource.java:57)
at com.google.android.exoplayer2.source.ExtractorMediaPeriod$ExtractingLoadable.load(ExtractorMediaPeriod.java:841)
at com.google.android.exoplayer2.upstream.Loader$LoadTask.run(Loader.java:308)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at java.lang.Thread.run(Thread.java:764)
Please Help

@MarkDylan100
Copy link

MarkDylan100 commented Jul 17, 2018

@mekya how cant I catch the error?

`private fun play(rtmpUri: String) {
    try {
        player = ExoPlayerFactory.newSimpleInstance(
                DefaultRenderersFactory(this), DefaultTrackSelector(), DefaultLoadControl())
        val playerView = findViewById<SimpleExoPlayerView>(R.id.player_view)
        //val uri = Uri.parse(BuildConfig.STREAMING_URL)
        val uri = Uri.parse(rtmpUri)

        playerView.player = player

        val mediaSource = ExtractorMediaSource(uri, RtmpDataSourceFactory(), DefaultExtractorsFactory(), null, null)

        player?.prepare(mediaSource)
        player?.playWhenReady = true
    } catch (e: Exception) {
        println("invalid uri")
    }
}`

this try catch doesn't do anything

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants