Android Media Stream Error? java.io.FileNotFoundException: No content provider :http://

Go to this file https://github.com/Old-Geek/Radio/blob/master/app/src/main/java/org/oucho/radio/Player.java#L234 and change

player.setDataSource(context, Uri.parse(url));

to

player.setDataSource(url)

The problem is that void setDataSource (String path) Sets the data source (file-path or http/rtsp URL) to use.

path String: the path of the file, or the http/rtsp URL of the stream you want to play

the github code uses void setDataSource (Context context, Uri uri) which assumes uri to be of some form of ContentProvider

context Context: the Context to use when resolving the Uri
uri Uri: the Content URI of the data you want to play

Leave a Comment