--- old/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2014-07-09 20:42:22.868675400 +0400 +++ new/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2014-07-09 20:42:22.193089600 +0400 @@ -1254,8 +1254,11 @@ if (name.equals("IHDR")) { IHDR_width = getIntAttribute(node, "width"); IHDR_height = getIntAttribute(node, "height"); - IHDR_bitDepth = getEnumeratedAttribute(node, "bitDepth", - IHDR_bitDepths); + IHDR_bitDepth = + Integer.valueOf(IHDR_bitDepths[ + getEnumeratedAttribute(node, + "bitDepth", + IHDR_bitDepths)]); IHDR_colorType = getEnumeratedAttribute(node, "colorType", IHDR_colorTypeNames); IHDR_compressionMethod =