commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Damjan Jovanovic (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SANSELAN-55) ArrayIndexOutOfBounds exception throwing when get metadata
Date Mon, 17 Oct 2011 20:47:11 GMT

    [ https://issues.apache.org/jira/browse/SANSELAN-55?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129166#comment-13129166
] 

Damjan Jovanovic commented on SANSELAN-55:
------------------------------------------

I'm not sure. Here's what exiftool gives for that image:
-----------------------------------------------
$ exiftool -a -u -g1 stupidpic.jpg 
---- ExifTool ----
ExifTool Version Number         : 8.15
Warning                         : Bad IFD1 directory
---- System ----
File Name                       : stupidpic.jpg
Directory                       : Desktop
File Size                       : 413 kB
File Modification Date/Time     : 2011:10:17 22:28:23+02:00
File Permissions                : rw-r--r--
---- File ----
File Type                       : JPEG
MIME Type                       : image/jpeg
Exif Byte Order                 : Little-endian (Intel, II)
Image Width                     : 2610
Image Height                    : 1952
Encoding Process                : Baseline DCT, Huffman coding
Bits Per Sample                 : 8
Color Components                : 3
Y Cb Cr Sub Sampling            : YCbCr4:2:0 (2 2)
---- IFD0 ----
Modify Date                     : 2011:09:23 12:04:08
Camera Model Name               : ADR6300
Orientation                     : Unknown (0)
Flash                           : Unknown (0xffff)
Light Source                    : Unknown
Create Date                     : 2011:09:23 12:04:08
Metering Mode                   : Unknown (65535)
White Balance                   : Unknown (65535)
Image Height                    : 1952
Image Width                     : 3264
Make                            : HTC
---- ExifIFD ----
Other Image Start               : 260
Other Image Length              : 0
---- Composite ----
Image Size                      : 2610x1952
-----------------------------------------------

and Sanselan:
-----------------------------------------------
Exif metadata:
		Root: 
			Modify Date: '2011:09:23 12:04:08'
			Model: 'ADR6300'
			Orientation: 0
			Unknown Tag (0x9209): 65535
			Unknown Tag (0x9208): 0
			Unknown Tag (0x9004): '2011:09:23 12:04:08'
			Unknown Tag (0x9207): 65535
			Unknown Tag (0xa403): 65535
			Exif Offset: 218

		Exif: 
			Preview Image Length: 0

No Photoshop (IPTC) metadata.
-----------------------------------------------

So exiftool's "IFD0" and Sanselan's "Root" seem to agree - Sanselan doesn't recognise some
of the fields, but they are in the same order and have the same values. I'll have to investigate
further.

                
> ArrayIndexOutOfBounds exception throwing when get metadata
> ----------------------------------------------------------
>
>                 Key: SANSELAN-55
>                 URL: https://issues.apache.org/jira/browse/SANSELAN-55
>             Project: Commons Sanselan
>          Issue Type: Bug
>    Affects Versions: 0.94-incubator
>         Environment: Ubuntu 11.04/Liftweb/SBT
>            Reporter: Chka Davaadorj
>             Fix For: 0.94-incubator
>
>         Attachments: stupidpic.jpg, tiff-patch.txt
>
>
> This is the executed script: Sanselan.getMetadata(new File(filePath))
> But, this throws following exception:
> Caught and thrown by:
> Message: java.lang.ArrayIndexOutOfBoundsException
> 	java.lang.System.arraycopy(Native Method)
> 	org.apache.sanselan.common.byteSources.ByteSourceArray.getBlock(ByteSourceArray.java:52)
> 	org.apache.sanselan.formats.tiff.TiffField.fillInValue(TiffField.java:309)
> 	org.apache.sanselan.formats.tiff.TiffReader.readDirectory(TiffReader.java:195)
> 	org.apache.sanselan.formats.tiff.TiffReader.readDirectory(TiffReader.java:110)
> 	org.apache.sanselan.formats.tiff.TiffReader.readDirectories(TiffReader.java:101)
> 	org.apache.sanselan.formats.tiff.TiffReader.read(TiffReader.java:448)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message