I'm trying to convert a gif to a jpeg using imageIO but the resulting image is pink... Anyone can help?
public byte[] convert(byte[] bytes)
throws Exception {
    ByteArrayInputStream inputStream = new ByteArrayInputStream(bytes);
    BufferedImage bufferedImage = ImageIO.read(inputStream); 
    ByteArrayOutputStream osByteArray = new ByteArrayOutputStream();
    ImageOutputStream outputStream = ImageIO.createImageOutputStream(osByteArray);
    ImageIO.write(bufferedImage, "jpg", outputStream);
    outputStream.flush();
    outputStream.close();
    return osByteArray.toByteArray();
}