diff options
author | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-11-26 06:40:06 +0000 |
---|---|---|
committer | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-11-26 06:40:06 +0000 |
commit | 3ba4fffb3acee18273ec9658520224c193f621af (patch) | |
tree | 9c832cb85fa044528c84acb63e744ae94c2fc47d /libjava/include | |
parent | 424c597eadffdf1dc8ada7ebadfc26d49be9ee13 (diff) | |
download | gcc-3ba4fffb3acee18273ec9658520224c193f621af.tar.gz |
Fix for PR libgcj/2024, plus other class name cleanups:
* include/jvm.h (_Jv_VerifyFieldSignature,
_Jv_VerifyMethodSignature, _Jv_VerifyClassName,
_Jv_VerifyIdentifier, _Jv_ClassNameSamePackage): Moved from ...
* include/java-interp.h: ... here.
* defineclass.cc (UTF8_PEEK): No longer conditional on
interpreter.
(_Jv_VerifyOne): Likewise.
(_Jv_VerifyFieldSignature): Likewise.
(_Jv_VerifyMethodSignature): Likewise.
(is_identifier_start): Likewise.
(is_identifier_part): Likewise.
(_Jv_VerifyIdentifier): Likewise.
(_Jv_VerifyClassName): Likewise.
(_Jv_VerifyClassName): Likewise.
(_Jv_ClassNameSamePackage): Likewise.
(_Jv_VerifyClassName): Fail if class name is too long.
* java/lang/natClassLoader.cc (_Jv_NewArrayClass): Disallow array
of void.
* java/lang/natClass.cc (forName): Check syntax of class name.
Include IllegalArgumentException.h.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@47334 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/include')
-rw-r--r-- | libjava/include/java-interp.h | 6 | ||||
-rw-r--r-- | libjava/include/jvm.h | 8 |
2 files changed, 8 insertions, 6 deletions
diff --git a/libjava/include/java-interp.h b/libjava/include/java-interp.h index 8eeb0949378..bc1f3ca1cf4 100644 --- a/libjava/include/java-interp.h +++ b/libjava/include/java-interp.h @@ -33,12 +33,6 @@ _Jv_IsInterpretedClass (jclass c) struct _Jv_ResolvedMethod; -bool _Jv_VerifyFieldSignature (_Jv_Utf8Const*sig); -bool _Jv_VerifyMethodSignature (_Jv_Utf8Const*sig); -bool _Jv_VerifyClassName (unsigned char* ptr, _Jv_ushort length); -bool _Jv_VerifyClassName (_Jv_Utf8Const *name); -bool _Jv_VerifyIdentifier (_Jv_Utf8Const *); -bool _Jv_ClassNameSamePackage (_Jv_Utf8Const *name1, _Jv_Utf8Const *name2); void _Jv_DefineClass (jclass, jbyteArray, jint, jint); void _Jv_InitField (jobject, jclass, int); diff --git a/libjava/include/jvm.h b/libjava/include/jvm.h index 858d960bf20..1cba08cf675 100644 --- a/libjava/include/jvm.h +++ b/libjava/include/jvm.h @@ -341,6 +341,14 @@ void _Jv_SetCurrentJNIEnv (_Jv_JNIEnv *); struct _Jv_JavaVM; _Jv_JavaVM *_Jv_GetJavaVM (); +// Some verification functions from defineclass.cc. +bool _Jv_VerifyFieldSignature (_Jv_Utf8Const*sig); +bool _Jv_VerifyMethodSignature (_Jv_Utf8Const*sig); +bool _Jv_VerifyClassName (unsigned char* ptr, _Jv_ushort length); +bool _Jv_VerifyClassName (_Jv_Utf8Const *name); +bool _Jv_VerifyIdentifier (_Jv_Utf8Const *); +bool _Jv_ClassNameSamePackage (_Jv_Utf8Const *name1, _Jv_Utf8Const *name2); + #ifdef ENABLE_JVMPI #include "jvmpi.h" |