PQ72327: ACTIVEX BRIDGE THROWS JAVA.LANG.ARRAYINDEXOUTOFBOUNDSEXCEPTION USING 0 LENGTH ARRAYS. | |||||||||||||||||||||||||||||||||||||||||
![]() |
|||||||||||||||||||||||||||||||||||||||||
![]() APAR status Closed as program error. Error description There are several problems related to the ActiveX bridge and it's handling of arrays: . 1. Zero length String and Object arrays cause java.lang.ArrayIndexOutOfBoundsException . 2. Arrays with multiple instance types (inherited from a base class) do not work.Local fix Problem summary **************************************************************** * USERS AFFECTED: WebSphere Application Server Client * * users running ActiveX applications that * * access zero length Java arrays or access * * Java arrays with multiple instance types. * **************************************************************** * PROBLEM DESCRIPTION: An ArrayIndexOutOfBoundsException is * * thrown when accessing a zero length * * Java array from an ActiveX * * application. * * * * An IllegalArgumentException is thrown * * when accessing a Java array that * * contains objects of different instance * * types inherited from a base class. * * * **************************************************************** * RECOMMENDATION: * **************************************************************** The ActiveX Bridge code was incorrectly handling zero length arrays and would throw: java.lang.ArrayIndexOutOfBoundsException at java.lang.reflect.Array.get(Native Method) at com.ibm.ws.client.xjb.XJBByteWriter.getArrayDims (XJBByteWriter.java:153) at com.ibm.ws.client.xjb.XJBByteWriter.putArray (XJBByteWriter.java:274) at com.ibm.ws.client.xjb.XJBByteWriter.putJVariant (XJBByteWriter.java:343) at com.ibm.ws.client.xjb.JDispatch.dispInvoke (JDispatch.java:777) Also, the ActiveX bridge was incorrectly handling Java arrays that contained different instance type of objects that are inhertied from a common base class. The following exception was thrown: java.lang.IllegalArgumentException: array element type mismatch at java.lang.reflect.Array.set(Native Method) at com.ibm.ws.client.xjb.JDispatch.getParamsFromJVariantArray (JDispatch.java:1159) at com.ibm.ws.client.xjb.JDispatch.getParamsFromJDispParams (JDispatch.java:1060) at com.ibm.ws.client.xjb.JDispatch.dispInvoke (JDispatch.java:362)Problem conclusion The ActiveX Bridge code was changed to handle zero length Java arrays and Java arrays with multiple instances types.Temporary fix Comments
APAR is sysrouted FROM one or more of the following: PQ68860 APAR is sysrouted TO one or more of the following: Modules/Macros
Publications Referenced
|
Product categories: Software > Application Servers >
Distributed Application & Web Servers > WebSphere Application
Server > General
Operating system(s):
Software version: 00W
Software edition:
Reference #: PQ72327
IBM Group: Software Group
Modified date: Mar 21, 2003
(C) Copyright IBM Corporation 2000, 2008. All Rights Reserved.