summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick Scott <phanna@android.com>2010-07-01 11:55:49 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-07-01 11:55:49 -0700
commite7023b0b4fdee9e2b1f503e8fdea2aeeb1d4a914 (patch)
treea1fa12cdd9e6605f42ed44e26c128f5892482339
parent3096b5dbd65490f575e632d43a9320b01c6816aa (diff)
parent939d1819c550af9e179aa2fa46668206333e1ebc (diff)
downloadexternal_webkit-e7023b0b4fdee9e2b1f503e8fdea2aeeb1d4a914.zip
external_webkit-e7023b0b4fdee9e2b1f503e8fdea2aeeb1d4a914.tar.gz
external_webkit-e7023b0b4fdee9e2b1f503e8fdea2aeeb1d4a914.tar.bz2
am 939d1819: am 9d4701f9: Push a local reference frame to avoid table overflow.
Merge commit '939d1819c550af9e179aa2fa46668206333e1ebc' * commit '939d1819c550af9e179aa2fa46668206333e1ebc': Push a local reference frame to avoid table overflow.
-rw-r--r--WebCore/bridge/jni/v8/JavaInstanceV8.cpp17
-rw-r--r--WebCore/bridge/jni/v8/JavaInstanceV8.h4
2 files changed, 13 insertions, 8 deletions
diff --git a/WebCore/bridge/jni/v8/JavaInstanceV8.cpp b/WebCore/bridge/jni/v8/JavaInstanceV8.cpp
index 3a2cb8b..59aa104 100644
--- a/WebCore/bridge/jni/v8/JavaInstanceV8.cpp
+++ b/WebCore/bridge/jni/v8/JavaInstanceV8.cpp
@@ -32,14 +32,9 @@
#include "JavaClassV8.h"
#include <assert.h>
-#include <utils/Log.h>
#define LOG_TAG "v8binding"
-
-// ANDROID
-#include <cutils/log.h>
-#define LOG_TAG JavaInstanceV8.cpp
-// END ANDROID
+#include <utils/Log.h>
using namespace JSC::Bindings;
@@ -55,6 +50,16 @@ JavaInstance::~JavaInstance()
delete m_class;
}
+#define NUM_LOCAL_REFS 64
+
+void JavaInstance::virtualBegin() {
+ getJNIEnv()->PushLocalFrame(NUM_LOCAL_REFS);
+}
+
+void JavaInstance::virtualEnd() {
+ getJNIEnv()->PopLocalFrame(0);
+}
+
JavaClass* JavaInstance::getClass() const
{
if (!m_class)
diff --git a/WebCore/bridge/jni/v8/JavaInstanceV8.h b/WebCore/bridge/jni/v8/JavaInstanceV8.h
index c928c05..4f009a5 100644
--- a/WebCore/bridge/jni/v8/JavaInstanceV8.h
+++ b/WebCore/bridge/jni/v8/JavaInstanceV8.h
@@ -89,8 +89,8 @@ protected:
RefPtr<JObjectWrapper> m_instance;
mutable JavaClass* m_class;
- virtual void virtualBegin() {}
- virtual void virtualEnd() {}
+ virtual void virtualBegin();
+ virtual void virtualEnd();
};
} // namespace Bindings