diff libinterp/octave-value/ov-java.cc @ 15816:59b6c6aee042

Don't box return values from javaObject. Always return a Java object. * libinterp/octave-value/ov-java.cc(do_javaObject): Don't call box() on newly created Java object. * scripts/general/fieldnames.m: Work-around bug with java.lang.String objects by calling getFields with class name rather than object. * scripts/general/methods.m: Work-around bug with java.lang.String objects by calling getMethods with class name rather than object.
author Rik <rik@octave.org>
date Tue, 18 Dec 2012 11:54:57 -0800
parents f28b3dcbaa9a
children 00172e5c2302
line wrap: on
line diff
--- a/libinterp/octave-value/ov-java.cc	Tue Dec 18 11:39:24 2012 -0800
+++ b/libinterp/octave-value/ov-java.cc	Tue Dec 18 11:54:57 2012 -0800
@@ -1793,7 +1793,7 @@
                                                                         jstring (clsName), jobjectArray (arg_objs), jobjectArray (arg_types)));
 
           if (resObj)
-            retval = box (jni_env, resObj);
+            retval = octave_value (new octave_java (resObj, 0));
           else
             check_exception (jni_env);
         }