exif.go: Log the byte-order

pull/69/head
Dustin Oprea 2021-04-27 21:40:05 -04:00
parent d154f10435
commit a1cb4443b2
1 changed files with 2 additions and 0 deletions

View File

@ -250,9 +250,11 @@ func ParseExifHeader(data []byte) (eh ExifHeader, err error) {
}
if bytes.Equal(data[:4], ExifBigEndianSignature[:]) == true {
exifLogger.Debugf(nil, "Byte-order is big-endian.")
eh.ByteOrder = binary.BigEndian
} else if bytes.Equal(data[:4], ExifLittleEndianSignature[:]) == true {
eh.ByteOrder = binary.LittleEndian
exifLogger.Debugf(nil, "Byte-order is little-endian.")
} else {
return eh, ErrNoExif
}