[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 3b2421e: Prevent subprocess hangs in xwidget
From: |
Po Lu |
Subject: |
master 3b2421e: Prevent subprocess hangs in xwidget |
Date: |
Wed, 17 Nov 2021 08:33:04 -0500 (EST) |
branch: master
commit 3b2421e6a7218b128c45ec2dd1f65a24d178093a
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>
Prevent subprocess hangs in xwidget
* src/xwidget.c (Fmake_xwidget, Fxwidget_webkit_goto_url): Use
`catch_child_signal' instead of trying to preserve the previous
signal handler.
---
src/xwidget.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/xwidget.c b/src/xwidget.c
index e1d54d4..e1bf40e 100644
--- a/src/xwidget.c
+++ b/src/xwidget.c
@@ -32,6 +32,7 @@ along with GNU Emacs. If not, see
<https://www.gnu.org/licenses/>. */
#include "sysstdio.h"
#include "termhooks.h"
#include "window.h"
+#include "process.h"
/* Include xwidget bottom end headers. */
#ifdef USE_GTK
@@ -189,14 +190,12 @@ fails. */)
{
xw->widget_osr = webkit_web_view_new ();
+ webkit_web_view_load_uri (WEBKIT_WEB_VIEW (xw->widget_osr),
+ "about:blank");
/* webkitgtk uses GSubprocess which sets sigaction causing
Emacs to not catch SIGCHLD with its usual handle setup in
'catch_child_signal'. This resets the SIGCHLD sigaction. */
- struct sigaction old_action;
- sigaction (SIGCHLD, NULL, &old_action);
- webkit_web_view_load_uri (WEBKIT_WEB_VIEW (xw->widget_osr),
- "about:blank");
- sigaction (SIGCHLD, &old_action, NULL);
+ catch_child_signal ();
}
else
{
@@ -1841,6 +1840,7 @@ DEFUN ("xwidget-webkit-goto-uri",
uri = ENCODE_FILE (uri);
#ifdef USE_GTK
webkit_web_view_load_uri (WEBKIT_WEB_VIEW (xw->widget_osr), SSDATA (uri));
+ catch_child_signal ();
#elif defined NS_IMPL_COCOA
nsxwidget_webkit_goto_uri (xw, SSDATA (uri));
#endif
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 3b2421e: Prevent subprocess hangs in xwidget,
Po Lu <=