2006/8/11, Jimmy, Jing Lv <[EMAIL PROTECTED]>:
Hi, As discussed in the former thread, I find that a JNI of DRLVM (GetByteArrayRegion) differs from RI in passing parameter (byte[count],count,0). RI (and J9 VM) returns immediately but DRLVM throws an ArrayIndexOutOfBoundsException. IMHO, it is better to improve here, make it follow RI, as JNI is also a part of API, and users may use it. So if no objections, shall I or someone raise a JIRA for this? I don't know if Martin is urgent in using Harmony in Winstone servlet engine (Martin, can you read this?), so shall I work around in java code before we have conclusion? Any comments/suggestions from DRLVM guys? Thanks!
I didn't really understand the condition when vm throws AIOBE. Do you pass start parameter count for the array of count length? But in this case the start points to the element right after the array end. And spec [1] explicitly states that this function should throw AIOBE in this case. Is there something I don't understand? [1] http://java.sun.com/j2se/1.5.0/docs/guide/jni/spec/functions.html#wp6212 -- Gregory Shimansky, Intel Middleware Products Division