title: Skia error when trying to retrieve a bitmap downloaded from Google Sign-in
body: <p>So, I am downloading the profile picture from the <code>Google SIgn-in api</code> and I save it to a hidden file. The problem is that when I try to retrieve it, it throws me: <code>D/skia: --- Failed to create image decoder with message 'unimplemented'</code>. However when I retrieve an image from <code>FireBaseStorage</code> and save that one to the hidden file I can retrieve it whithout any problems.</p>
  
  <p>I tried BitmapFactory.decodeByteArray(), but then I had a message telling me skia wasn't able to decode the file and it returned null.</p>
  
  <p>The method I use to retrieve the profile picture and call the method that will save the file</p>
  
  <pre><code>private void getUsersPic() {
          Bitmap profilePic;
  
          try {
              InputStream in = new URL(AppData.getUser().getPicture()).openConnection().getInputStream();
              profilePic = BitmapFactory.decodeStream(in);
  
              int size = profilePic.getRowBytes()*profilePic.getHeight();
  
              ByteBuffer b = ByteBuffer.allocate(size);
              byte[] bytes = new byte[size];
  
              profilePic.copyPixelsToBuffer(b);
  
              b.position(0);
              b.get(bytes, 0, bytes.length);
  
              SaveBitmapToFile.saveBitmap(bytes , AppData.getUser().getName()+AppData.getUser().getLastName());
  
          } catch(Exception e) {
              System.out.println("Get profile pic: "+e.toString());
          }
      }
  </code></pre>
  
  <p>Save the file</p>
  
  <pre><code>public static void saveBitmap(byte[] bitmap, String key) {
  
          String path = AppData.getAppContext().getFilesDir()+"/.image"+"/";
  
          File fileDir = new File(path);
  
          if(!fileDir.isDirectory())
              fileDir.mkdirs();
  
  
          try {
              File bitmapDir = new File(fileDir+"/"+key);
              bitmapDir.createNewFile();
              FileOutputStream stream = new FileOutputStream(bitmapDir);
  
              stream.write(bitmap);
              stream.close();
  
          } catch (IOException e) {
              System.out.println("Problem creating file "+e.toString()+ " Directory: "+fileDir);
          }
      }
  </code></pre>
  
  <p>Retrieve and return a bitmap</p>
  
  <pre><code> public static Bitmap getBitmap(String key) {
  
          File file = new File(AppData.getAppContext().getFilesDir()+"/.image/"+key);
  
          try {
              BufferedInputStream buf = new BufferedInputStream(new FileInputStream(file));
              return BitmapFactory.decodeStream(buf);//BitmapFactory.decodeByteArray(bytes, 0, bytes.length);
  
          } catch(Exception e) {
              System.out.println("Exception getting bitmap: "+e.toString());
              return null;
          }
      }
  </code></pre>
  
  <p>The last method should return a Bitmap and it is doing it. It is just not working when the image comes from the Google Sign-in api. </p>