Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 151428 Details for
Bug 234836
Can't register openoffice.org java components
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
patch to make work
aph.makejavaregwork.patch (text/plain), 5.24 KB, created by
Caolan McNamara
on 2007-04-02 14:27:14 UTC
(
hide
)
Description:
patch to make work
Filename:
MIME Type:
Creator:
Caolan McNamara
Created:
2007-04-02 14:27:14 UTC
Size:
5.24 KB
patch
obsolete
>diff -ru gcc-4.1.2-20070329.orig/libjava/java/lang/Class.h gcc-4.1.2-20070329/libjava/java/lang/Class.h >--- gcc-4.1.2-20070329.orig/libjava/java/lang/Class.h 2007-03-27 14:57:49.000000000 +0100 >+++ gcc-4.1.2-20070329/libjava/java/lang/Class.h 2007-04-02 12:01:08.000000000 +0100 >@@ -237,6 +237,8 @@ > java::lang::reflect::Method *_Jv_GetReflectedMethod (jclass klass, > _Jv_Utf8Const *name, > _Jv_Utf8Const *signature); >+java::lang::reflect::Method *_Jv_LookupProxyMethod (jclass, _Jv_Utf8Const *, >+ _Jv_Utf8Const *); > jfieldID JvGetFirstInstanceField (jclass); > jint JvNumInstanceFields (jclass); > jfieldID JvGetFirstStaticField (jclass); >@@ -542,6 +544,8 @@ > friend java::lang::reflect::Method* ::_Jv_GetReflectedMethod (jclass klass, > _Jv_Utf8Const *name, > _Jv_Utf8Const *signature); >+ friend java::lang::reflect::Method *::_Jv_LookupProxyMethod (jclass, _Jv_Utf8Const *, >+ _Jv_Utf8Const *); > friend jfieldID (::JvGetFirstInstanceField) (jclass); > friend jint (::JvNumInstanceFields) (jclass); > friend jfieldID (::JvGetFirstStaticField) (jclass); >diff -ru gcc-4.1.2-20070329.orig/libjava/java/lang/natClass.cc gcc-4.1.2-20070329/libjava/java/lang/natClass.cc >--- gcc-4.1.2-20070329.orig/libjava/java/lang/natClass.cc 2007-03-27 14:57:49.000000000 +0100 >+++ gcc-4.1.2-20070329/libjava/java/lang/natClass.cc 2007-04-02 12:00:22.000000000 +0100 >@@ -29,6 +29,7 @@ > #include <java/lang/reflect/Member.h> > #include <java/lang/reflect/Method.h> > #include <java/lang/reflect/Field.h> >+#include <java/lang/reflect/Proxy.h> > #include <java/lang/reflect/Constructor.h> > #include <java/lang/AbstractMethodError.h> > #include <java/lang/ArrayStoreException.h> >@@ -1640,6 +1641,35 @@ > } > > java::lang::reflect::Method * >+_Jv_LookupProxyMethod (jclass proxyClass, _Jv_Utf8Const *name, >+ _Jv_Utf8Const *signature) >+{ >+ using namespace java::lang::reflect; >+ jclass declaringClass; >+ _Jv_Method * m; >+ >+ for (int i = 0; i < proxyClass->interface_count; i++) >+ { >+ declaringClass = proxyClass->interfaces[i]; >+ m = _Jv_GetMethodLocal (declaringClass, name, signature); >+ if (m) >+ break; >+ } >+ if (!m) >+ m = _Jv_LookupDeclaredMethod (&Proxy::class$, >+ name, >+ signature, >+ &declaringClass); >+ >+ Method *rmethod = new Method (); >+ rmethod->offset = (char*) m - (char*) declaringClass->methods; >+ rmethod->declaringClass = declaringClass; >+ return rmethod; >+} >+ >+ >+ >+java::lang::reflect::Method * > _Jv_GetReflectedMethod (jclass klass, _Jv_Utf8Const *name, > _Jv_Utf8Const *signature) > { >diff -ru gcc-4.1.2-20070329.orig/libjava/java/lang/reflect/natVMProxy.cc gcc-4.1.2-20070329/libjava/java/lang/reflect/natVMProxy.cc >--- gcc-4.1.2-20070329.orig/libjava/java/lang/reflect/natVMProxy.cc 2007-03-27 14:57:50.000000000 +0100 >+++ gcc-4.1.2-20070329/libjava/java/lang/reflect/natVMProxy.cc 2007-04-02 12:02:20.000000000 +0100 >@@ -301,6 +301,8 @@ > void **args, > void*user_data) > { >+ using namespace java::lang::reflect; >+ > Proxy *proxy = *(Proxy**)args[0]; > ncode_closure *self = (ncode_closure *) user_data; > >@@ -312,17 +314,23 @@ > Thread *thread = Thread::currentThread(); > _Jv_InterpFrame frame_desc (self->self, thread, proxy->getClass()); > >- Method *meth = _Jv_GetReflectedMethod (proxy->getClass(), >- self->self->name, >- self->self->signature); >+ Method *meth = _Jv_LookupProxyMethod (proxy->getClass(), >+ self->self->name, >+ self->self->signature); >+ > JArray<jclass> *parameter_types = meth->internalGetParameterTypes (); > JArray<jclass> *exception_types = meth->internalGetExceptionTypes (); > > InvocationHandler *handler = proxy->h; >- void *poo >- = _Jv_NewObjectArray (parameter_types->length, &Object::class$, NULL); >- JArray<jobject> *argsArray = (JArray<jobject> *) poo; >- jobject *jargs = elements(argsArray); >+ JArray<jobject> *argsArray = NULL; >+ jobject *jargs = NULL; >+ if (parameter_types->length) >+ { >+ void *poo >+ = _Jv_NewObjectArray (parameter_types->length, &Object::class$, NULL); >+ argsArray = (JArray<jobject> *) poo; >+ jargs = elements(argsArray); >+ } > > // FIXME: It must be possible to use fast interface dispatch here, > // but I've not quite figured out how to do it. >--- gcc-4.1.2-20070329.orig/libjava/headers.txt 2007-03-12 07:19:49.000000000 +0000 >+++ gcc-4.1.2-20070329/libjava/headers.txt 2007-04-02 14:57:43.000000000 +0100 >@@ -57,11 +57,13 @@ > prepend jmethodID _Jv_FromReflectedMethod (java::lang::reflect::Method *); > prepend jobject _Jv_JNI_ToReflectedMethod (_Jv_JNIEnv *, jclass, jmethodID, jboolean); > prepend ::java::lang::reflect::Method *_Jv_GetReflectedMethod (jclass, _Jv_Utf8Const*, _Jv_Utf8Const*); >+prepend ::java::lang::reflect::Method *_Jv_LookupProxyMethod (jclass, _Jv_Utf8Const*, _Jv_Utf8Const*); > friend jmethodID (::_Jv_FromReflectedMethod) (java::lang::reflect::Method *); > friend jobject (::_Jv_JNI_ToReflectedMethod) (_Jv_JNIEnv *, jclass, jmethodID, jboolean); > friend class java::lang::Class; > friend class java::io::ObjectInputStream; > friend java::lang::reflect::Method* ::_Jv_GetReflectedMethod (jclass, _Jv_Utf8Const*, _Jv_Utf8Const*); >+friend java::lang::reflect::Method* ::_Jv_LookupProxyMethod (jclass, _Jv_Utf8Const*, _Jv_Utf8Const*); > > class gnu/gcj/runtime/ExtensionClassLoader > friend class ::java::lang::ClassLoader;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 234836
: 151428