aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAkira Kyle2020-11-09 14:51:48 +0100
committerLars Ingebrigtsen2020-11-09 14:51:48 +0100
commita05810b2d5f1a87ad1b20c4e61adc464a31e315d (patch)
tree1adde05d71a0bd4a766d4dcc7551a29219bd3a8c /src
parent3289b96abd12058439f02e84415793acb44a733b (diff)
downloademacs-a05810b2d5f1a87ad1b20c4e61adc464a31e315d.tar.gz
emacs-a05810b2d5f1a87ad1b20c4e61adc464a31e315d.zip
Fix xwidget's webkitgtk widget overriding of Emacs SIGCHLD handler
* src/xwidget.c (make-xwidget): Save and restore Emacs SIGCHLD signal handler since glib doesn't (but should) do this. Copyright-paperwork-exempt: yes
Diffstat (limited to 'src')
-rw-r--r--src/xwidget.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/xwidget.c b/src/xwidget.c
index 031975fafb9..e078a28a35b 100644
--- a/src/xwidget.c
+++ b/src/xwidget.c
@@ -128,6 +128,16 @@ Returns the newly constructed xwidget, or nil if construction fails. */)
128 if (EQ (xw->type, Qwebkit)) 128 if (EQ (xw->type, Qwebkit))
129 { 129 {
130 xw->widget_osr = webkit_web_view_new (); 130 xw->widget_osr = webkit_web_view_new ();
131
132 /* webkitgtk uses GSubprocess which sets sigaction causing
133 Emacs to not catch SIGCHLD with its usual handle setup in
134 catch_child_signal(). This resets the SIGCHLD
135 sigaction. */
136 struct sigaction old_action;
137 sigaction (SIGCHLD, NULL, &old_action);
138 webkit_web_view_load_uri(WEBKIT_WEB_VIEW (xw->widget_osr),
139 "about:blank");
140 sigaction (SIGCHLD, &old_action, NULL);
131 } 141 }
132 142
133 gtk_widget_set_size_request (GTK_WIDGET (xw->widget_osr), xw->width, 143 gtk_widget_set_size_request (GTK_WIDGET (xw->widget_osr), xw->width,