jni.cc (_Jv_JNI_check_types): New.
2003-06-11 Andrew Haley <aph@redhat.com> * jni.cc (_Jv_JNI_check_types): New. (_Jv_JNI_SetPrimgitiveArrayRegion): Check array type. (_Jv_JNI_GetPrimitiveArrayRegion): Ditto. (_Jv_JNI_GetPrimitiveArrayElements): Ditto. (_Jv_JNI_ReleasePrimitiveArrayElements): Ditto. * java/lang/natVMSecurityManager.cc (getClassContext): Fix infinite loop. From-SVN: r67835
This commit is contained in:
parent
14b96a951a
commit
e976ed37ef
3 changed files with 109 additions and 42 deletions
|
@ -28,9 +28,9 @@ java::lang::VMSecurityManager::getClassContext ()
|
|||
int maxlen = t->length();
|
||||
|
||||
int len = 0;
|
||||
while (len < maxlen)
|
||||
for (int i=0; i<len; i++)
|
||||
{
|
||||
jclass klass = t->classAt(len);
|
||||
jclass klass = t->classAt(i);
|
||||
if (klass != NULL && klass != &java::lang::VMSecurityManager::class$
|
||||
&& klass != &java::lang::SecurityManager::class$)
|
||||
++len;
|
||||
|
@ -41,9 +41,9 @@ java::lang::VMSecurityManager::getClassContext ()
|
|||
NULL);
|
||||
|
||||
len = 0;
|
||||
while (len < maxlen)
|
||||
for (int i=0; i<len; i++)
|
||||
{
|
||||
jclass klass = t->classAt(len);
|
||||
jclass klass = t->classAt(i);
|
||||
if (klass != NULL && klass != &java::lang::VMSecurityManager::class$
|
||||
&& klass != &java::lang::SecurityManager::class$)
|
||||
elements(result)[len++] = klass;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue