Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8d9d499f authored by Linux Build Service Account's avatar Linux Build Service Account
Browse files

Merge 7c4557ea on remote branch

Change-Id: If1482133f406584b9d65242bdb765569ec6f0d4d
parents 0d9640fd 7c4557ea
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
ifeq ($(TARGET_FWK_SUPPORTS_FULL_VALUEADDS),true)
LOCAL_PATH:= $(call my-dir)

include $(CLEAR_VARS)
@@ -63,3 +64,4 @@ ifeq ($(strip $(LOCAL_PACKAGE_OVERRIDES)),)
include $(call all-makefiles-under, $(LOCAL_PATH))

endif
endif
+6 −0
Original line number Diff line number Diff line
@@ -106,6 +106,12 @@ public class CountedDataInputStream extends FilterInputStream {
        return readShort() & 0xffff;
    }

    public byte readByte() throws IOException {
        readOrThrow(mByteArray, 0 ,1);
        mByteBuffer.rewind();
        return mByteBuffer.get(0);
    }

    public int readInt() throws IOException {
        readOrThrow(mByteArray, 0 , 4);
        mByteBuffer.rewind();
+19 −14
Original line number Diff line number Diff line
@@ -140,6 +140,8 @@ class ExifParser {
    protected static final int OFFSET_SIZE = 2;

    private static final Charset US_ASCII = Charset.forName("US-ASCII");
    private static final byte APP1_UP = (byte)0xFF;
    private static final byte APP1_DOWN = (byte)0xE1;

    protected static final int DEFAULT_IFD0_OFFSET = 8;

@@ -784,15 +786,16 @@ class ExifParser {
                }
                marker = dataStream.readShort();
            }


        } else{
            dataStream.skip(6);
            if (dataStream.readInt() == HEIC_HEADER) {
                while(true){
                    try{
                        short marker = dataStream.readShort();
                        if (marker == JpegHeader.APP1) {
                        byte marker = dataStream.readByte();
                        if(marker == APP1_UP){
                            dataStream.mark(8);
                            marker = dataStream.readByte();
                            if (marker == APP1_DOWN){
                                int header = 0;
                                short headerTail = 0;
                                int length = dataStream.readUnsignedShort();
@@ -805,6 +808,8 @@ class ExifParser {
                                    return true;
                                }
                            }
                            dataStream.reset();
                        }
                    }catch (Exception e){
                        break;
                    }