6

I download a video from my remote server and saving it in application data directory. Once it is completed I pass its URL to video player (UI element on my window). Then my app crashes.

This is only happening on Marshmallow (Android version 6.0). I've tested it on Lollypop (4-5 devices) but it is working fine there.

I tried different solutions but am still not able to fix this issue. It is really killing me. If anyone of you have idea about it, please help. I would be grateful.

This is my log (from comments):

[ERROR] : TiVideoView8: java.io.IOException: setDataSource failed. [ERROR] : TiVideoView8: at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1095) [ERROR] : TiVideoView8: at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1041) [ERROR] : TiVideoView8: at android.media.MediaPlayer.setDataSource(MediaPlayer.java:987) [ERROR] : TiVideoView8: at android.media.MediaPlayer.setDataSource(MediaPlayer.java:968)

Floern
  • 33,559
  • 24
  • 104
  • 119
In-Vogue
  • 305
  • 1
  • 7

2 Answers2

1

You ran into TIMOB-20440 which is fixed in Titanium 5.3 (beta this week, GA 2 weeks later).

Fokke Zandbergen
  • 3,866
  • 1
  • 11
  • 28
0

This is a bug that did exists on earlier SDK of appceleration. But is fixed now. The bug arose because of new run time permission that is introduced in Andorid M. Fix version 5.3.0 or higher. There is work around though. Get the applicationDataDirectory permission using ti.permission module.

Saeed Sharman
  • 765
  • 5
  • 24