title: MediaPlayer returning Error (1,-2147483648) trying to play AWS cloudfront links
body: <p>The links that I get from my database correlate to videos on my S3 bucket, but every time I try to play one, it returns a (1,-2147483648)</p>
  
  <pre><code>public static ExploreFragment create(int pageNumber) {
      ExploreFragment fragment = new ExploreFragment();
      Bundle args = new Bundle();
      args.putInt(ARG_PAGE, pageNumber);
      fragment.setArguments(args);
      return fragment;
  }
  
  public ExploreFragment() {
  }
  
  
  @Override
  public View onCreateView(LayoutInflater inflater, ViewGroup container,
          Bundle savedInstanceState) {
      // Inflate the layout containing a title and body text.
      ViewGroup rootView = (ViewGroup) inflater
              .inflate(R.layout.fragmentlayout, container, false);
      vv1 = (SurfaceView) rootView.findViewById(R.id.VideoView1); 
      holder = vv1.getHolder();
      holder.addCallback(this);
      mp = new MediaPlayer();
      try {
          mp.setDataSource(links.get(getPageNumber()).trim());
      } catch (IllegalArgumentException e) {
          // TODO Auto-generated catch block
          e.printStackTrace();
      } catch (SecurityException e) {
          // TODO Auto-generated catch block
          e.printStackTrace();
      } catch (IllegalStateException e) {
          // TODO Auto-generated catch block
          e.printStackTrace();
      } catch (IOException e) {
          // TODO Auto-generated catch block
          e.printStackTrace();
      }
      mp.setOnPreparedListener(this);
      mp.prepareAsync();
      mp.start();
      return rootView;
  </code></pre>
  
  <p>"links" is just a List with all my links from cloudfront that I need to display on the ViewPager.</p>
  
  <p>This is the AsyncTask to pull the content:</p>
  
  <pre><code>    class PullContent extends AsyncTask&lt;Void,Void,String&gt; {
  
  
       public ArrayList&lt;String&gt; list = new ArrayList&lt;String&gt;();
       public ArrayList&lt;String&gt; linklist = new ArrayList&lt;String&gt;();
       public static ArrayList&lt;ArrayList&lt;String&gt;&gt; listoflists = new      ArrayList&lt;ArrayList&lt;String&gt;&gt;();
       public static String[] array;
  
       @Override
       protected String doInBackground(Void... params) {
      /*if(Long.parseLong(Constants.EXPIRATION_DATE) &lt; System.currentTimeMillis() +      15*60*100){
          new TokenRequest().execute(Constants.SECRETKEY_LOGIN);
      }*/
      HttpClient httpclient = new DefaultHttpClient();
      HttpResponse response;
  
      try {
          response = httpclient.execute(new HttpPost("http://davai.co/getkremlin"));
  
          InputStreamReader SearchReader = null;
          try {
              SearchReader = new InputStreamReader(response.getEntity().getContent());
          } catch (IllegalStateException e) {
              // TODO Auto-generated catch block
              e.printStackTrace();
          } catch (IOException e) {
              // TODO Auto-generated catch block
              e.printStackTrace();
          }
          BufferedReader ObjBuffer = new BufferedReader(SearchReader);
  
          String line = "";
          try {
              while((line = ObjBuffer.readLine())!= null){
                  list.add(line.trim());
                  if(list.size() == 2){
                      listoflists.add(list);
                      linklist.add(list.toString());
                      list.clear();
                  }
  
              }
              ExploreFragment.checked = true;
              getContent(linklist);
          } catch (IOException e) {
              Log.i("exception", "exception");// TODO Auto-generated catch block
              e.printStackTrace();
          }
  
      }
      catch(Exception exception){
          Log.i("exception", exception.getMessage());
          return null;
      }
      return null;
  }
  public void onPostExecute(String result){
  }
  private void getContent(ArrayList&lt;String&gt; linklist) {
      if(linklist.size()&gt;0){
          // TODO Auto-generated method stub
          for(String str:linklist){
              int indexofOpen = str.indexOf("[");
              int indexofClose = str.lastIndexOf("]");
              String res = str.substring(indexofOpen+1,indexofClose);
              String[] resarray = res.split(",");
              ExploreFragment.usernames.add(resarray[0].trim());
              ExploreFragment.links.add(resarray[2]);
              ExploreFragment.locations.add(resarray[3]);
              ExploreFragment.times.add(resarray[1]);
          }
      }else{
          new AlertDialogFrag();
      }
  </code></pre>