[gjs/gnome-3-34] function: Don't always js::DumpStack() in blocked callbacks
- From: Philip Chimento <pchimento src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs/gnome-3-34] function: Don't always js::DumpStack() in blocked callbacks
- Date: Wed, 13 Nov 2019 00:31:15 +0000 (UTC)
commit ddc0e279abf39c4eb0922fc035b48132c95cab41
Author: Philip Chimento <philip chimento gmail com>
Date: Fri Nov 1 23:17:46 2019 -0700
function: Don't always js::DumpStack() in blocked callbacks
Apparently js::DumpStack() doesn't work in a non-main thread. I thought
for sure when I added it in commit 6f26113a that it did, but maybe that
was in an old version of SpiderMonkey.
Closes: #287
gi/function.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/gi/function.cpp b/gi/function.cpp
index de7d84db..10e87aee 100644
--- a/gi/function.cpp
+++ b/gi/function.cpp
@@ -178,7 +178,6 @@ warn_about_illegal_js_callback(const GjsCallbackTrampoline *trampoline,
g_critical("The offending callback was %s()%s.", name,
trampoline->is_vfunc ? ", a vfunc" : "");
}
- gjs_dumpstack();
return;
}
@@ -207,6 +206,7 @@ static void gjs_callback_closure(ffi_cif* cif G_GNUC_UNUSED, void* result,
warn_about_illegal_js_callback(trampoline, "during shutdown",
"destroying a Clutter actor or GTK widget with ::destroy signal "
"connected, or using the destroy(), dispose(), or remove() vfuncs");
+ gjs_dumpstack();
gjs_callback_trampoline_unref(trampoline);
return;
}
@@ -217,6 +217,7 @@ static void gjs_callback_closure(ffi_cif* cif G_GNUC_UNUSED, void* result,
warn_about_illegal_js_callback(trampoline, "during garbage collection",
"destroying a Clutter actor or GTK widget with ::destroy signal "
"connected, or using the destroy(), dispose(), or remove() vfuncs");
+ gjs_dumpstack();
gjs_callback_trampoline_unref(trampoline);
return;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]