add an aditional null check at videofragments

This commit is contained in:
tibbi 2017-05-26 09:38:35 +02:00
parent 64fa74f6cd
commit 9d7834f294

View file

@ -289,7 +289,7 @@ class VideoFragment : ViewPagerFragment(), SurfaceHolder.Callback, SeekBar.OnSee
}
override fun surfaceChanged(holder: SurfaceHolder, format: Int, width: Int, height: Int) {
if (width != 0 && height != 0)
if (width != 0 && height != 0 && mSurfaceView != null)
setVideoSize()
}