[gjs] JS_IsNativeFrame replaced by JS_IsScriptFrame
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs] JS_IsNativeFrame replaced by JS_IsScriptFrame
- Date: Wed, 20 Oct 2010 20:41:30 +0000 (UTC)
commit da877651d1af5da29576a2e5daca705effc7a1a4
Author: Sardem FF7 <sardemff7 pub gmail com>
Date: Wed Oct 20 19:51:15 2010 +0200
JS_IsNativeFrame replaced by JS_IsScriptFrame
https://bugzilla.gnome.org/show_bug.cgi?id=632485
configure.ac | 2 ++
gjs/stack.c | 4 ++++
2 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 35c64c9..809a81d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -151,6 +151,8 @@ if `$PKG_CONFIG --exists $JS_PACKAGE '>=' 2`; then
AC_DEFINE(HAVE_MOZJS_2, [1], [Define if mozilla-js is at least 2])
AC_CHECK_LIB([mozjs], [JS_FreezeObject], AC_DEFINE([HAVE_JS_FREEZEOBJECT], [1], [Define if we have JS_FreezeObject]),
, [$JS_LIBS])
+ AC_CHECK_LIB([mozjs], [JS_IsScriptFrame], AC_DEFINE([HAVE_JS_ISSCRIPTFRAME], [1], [Define if we have JS_IsScriptFrame]),
+ , [$JS_LIBS])
else
AC_MSG_RESULT([no])
diff --git a/gjs/stack.c b/gjs/stack.c
index 5ae3b02..686a335 100644
--- a/gjs/stack.c
+++ b/gjs/stack.c
@@ -93,7 +93,11 @@ format_frame(JSContext* cx, JSStackFrame* fp,
(void)JS_EnterLocalRootScope(cx);
+#ifdef HAVE_JS_ISSCRIPTFRAME
+ if (!JS_IsScriptFrame(cx, fp)) {
+#else
if (JS_IsNativeFrame(cx, fp)) {
+#endif
g_string_append_printf(buf, "%d [native frame]\n", num);
goto out;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]