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

FATAL EXCEPTION: FinalizerWatchdogDaemon #30

Closed
codeskraps opened this issue Jun 10, 2014 · 2 comments
Closed

FATAL EXCEPTION: FinalizerWatchdogDaemon #30

codeskraps opened this issue Jun 10, 2014 · 2 comments
Labels

Comments

@codeskraps
Copy link

I'm testing ijkplayer with an app where I need to play some video one after the other. The videos are about 30 seconds average.

After the 5th or 6th video I keep getting this TOTAL FAILURE:

06-09 16:42:06.342: E/AndroidRuntime(5233): FATAL EXCEPTION: FinalizerWatchdogDaemon
06-09 16:42:06.342: E/AndroidRuntime(5233): java.util.concurrent.TimeoutException: tv.danmaku.ijk.media.player.IjkMediaPlayer.finalize() timed out after 10 seconds
06-09 16:42:06.342: E/AndroidRuntime(5233):     at tv.danmaku.ijk.media.player.IjkMediaPlayer.native_finalize(Native Method)
06-09 16:42:06.342: E/AndroidRuntime(5233):     at tv.danmaku.ijk.media.player.IjkMediaPlayer.finalize(IjkMediaPlayer.java:405)
06-09 16:42:06.342: E/AndroidRuntime(5233):     at java.lang.Daemons$FinalizerDaemon.doFinalize(Daemons.java:187)
06-09 16:42:06.342: E/AndroidRuntime(5233):     at java.lang.Daemons$FinalizerDaemon.run(Daemons.java:170)
06-09 16:42:06.342: E/AndroidRuntime(5233):     at java.lang.Thread.run(Thread.java:856)

The only way I've been able to continue working at the moment is by removing line 405 in IjkMediaPlayer

@bbcallen
Copy link
Contributor

remove this line may cause resource leak.

Try:

// pseudo-code in UIThread
currentPlayer.stop()
currentPlayer.setSurface(null)
runOnBackgroundThread(new Runnable() {
    public void run() {
        currentPlayer.shutdown();
        currentPlayer.release();
    }
})

newPlayer = new Player()
// blablabla
...

@bbcallen bbcallen added the bug label Jun 20, 2014
@bbcallen
Copy link
Contributor

fixed: 5f00a1b

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

No branches or pull requests

2 participants