harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Cornwall (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-5589) [classlib][pack200] AttributeLayout KS returning negative index
Date Wed, 12 Mar 2008 16:08:46 GMT

     [ https://issues.apache.org/jira/browse/HARMONY-5589?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Andrew Cornwall updated HARMONY-5589:
-------------------------------------

    Attachment:     (was: com.ibm.collaboration.realtime.alertmanager_7.5.1.20070416.jar)

> [classlib][pack200] AttributeLayout KS returning negative index
> ---------------------------------------------------------------
>
>                 Key: HARMONY-5589
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5589
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Pack200 HEAD
>            Reporter: Andrew Cornwall
>            Assignee: Sian January
>             Fix For: 5.0M6
>
>
> When running Pack200 on the attached testcase, I get a:
> Thread [main] (Suspended (exception Pack200Exception("Cannot have a negative range")))

> 	SegmentConstantPool.getValue(int, long) line: 65	
> 	AttributeLayout.getValue(String, long, SegmentConstantPool) line: 76	
> 	AttributeLayout.getValue(long, String, SegmentConstantPool) line: 198	
> 	ClassBands.parseFieldAttrBands(InputStream) line: 243	
> 	ClassBands.parseFieldBands(InputStream) line: 152	
> 	ClassBands.unpack(InputStream) line: 141	
> 	Segment.parseSegment(InputStream) line: 332	
> 	Segment.unpack(InputStream, JarOutputStream) line: 352	
> 	Archive.unpack() line: 146	
> 	TestUnpack.main(String[]) line: 15	
> This appears to be due to the fact that value is -116 at the following point in AttributeLayout.getValue():
> 		} else if (layout.startsWith("K")) { //$NON-NLS-1$
> 			char type = layout.charAt(1);
> 			switch (type) {
> 			case 'S': // String
> -->				return pool.getValue(SegmentConstantPool.CP_STRING, value);

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message