Apply patch for Java to fix direct use of a weak global reference in directors sometimes causing seg faults especially on Android.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13834 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
608d43f0f9
commit
b38722e8ee
3 changed files with 6 additions and 3 deletions
|
|
@ -4,6 +4,10 @@ See the RELEASENOTES file for a summary of changes in each release.
|
|||
|
||||
Version 2.0.9 (in progress)
|
||||
===========================
|
||||
2012-09-11: wsfulton
|
||||
[Java] Fix #3535304 - Direct use of a weak global reference in directors
|
||||
sometimes causing seg faults especially on Android.
|
||||
|
||||
2012-09-06: wsfulton
|
||||
[Java] Fix (char *STRING, size_t LENGTH) typemaps to accept NULL string.
|
||||
|
||||
|
|
|
|||
|
|
@ -118,9 +118,7 @@ public class SwigExtend extends Activity
|
|||
|
||||
// Time to delete the EmployeeList, which will delete all the Employee*
|
||||
// items it contains. The last item is our CEO, which gets destroyed as well.
|
||||
/* Causes app to die
|
||||
list.delete();
|
||||
*/
|
||||
outputText.append( "----------------------\n" );
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -149,7 +149,7 @@ namespace Swig {
|
|||
void swig_disconnect_director_self(const char *disconn_method) {
|
||||
JNIEnvWrapper jnienv(this) ;
|
||||
JNIEnv *jenv = jnienv.getJNIEnv() ;
|
||||
jobject jobj = swig_self_.peek();
|
||||
jobject jobj = swig_self_.get(jenv);
|
||||
#if defined(DEBUG_DIRECTOR_OWNED)
|
||||
std::cout << "Swig::Director::disconnect_director_self(" << jobj << ")" << std::endl;
|
||||
#endif
|
||||
|
|
@ -162,6 +162,7 @@ namespace Swig {
|
|||
jenv->CallVoidMethod(jobj, disconn_meth);
|
||||
}
|
||||
}
|
||||
jenv->DeleteLocalRef(jobj);
|
||||
}
|
||||
|
||||
public:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue