From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#24041: 25.1.50; xwidget + -nw mode gives segfault Date: Sat, 20 Aug 2016 10:32:03 +0300 Message-ID: <83oa4ndhfw.fsf@gnu.org> References: <8760qwtxld.fsf@cochranmail.com> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1471678402 13656 195.159.176.226 (20 Aug 2016 07:33:22 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 20 Aug 2016 07:33:22 +0000 (UTC) Cc: shanemhansen@gmail.com, 24041@debbugs.gnu.org To: Robert Cochran Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Aug 20 09:33:17 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bb0mL-0003Mp-Ix for geb-bug-gnu-emacs@m.gmane.org; Sat, 20 Aug 2016 09:33:17 +0200 Original-Received: from localhost ([::1]:60158 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bb0mI-0001Th-Ky for geb-bug-gnu-emacs@m.gmane.org; Sat, 20 Aug 2016 03:33:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34297) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bb0mC-0001TZ-8q for bug-gnu-emacs@gnu.org; Sat, 20 Aug 2016 03:33:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bb0m6-0003Eb-GC for bug-gnu-emacs@gnu.org; Sat, 20 Aug 2016 03:33:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:36944) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bb0m6-0003EW-Cm for bug-gnu-emacs@gnu.org; Sat, 20 Aug 2016 03:33:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bb0m6-0002AK-5U for bug-gnu-emacs@gnu.org; Sat, 20 Aug 2016 03:33:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 20 Aug 2016 07:33:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24041 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24041-submit@debbugs.gnu.org id=B24041.14716783268253 (code B ref 24041); Sat, 20 Aug 2016 07:33:02 +0000 Original-Received: (at 24041) by debbugs.gnu.org; 20 Aug 2016 07:32:06 +0000 Original-Received: from localhost ([127.0.0.1]:34656 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bb0lC-000293-Lx for submit@debbugs.gnu.org; Sat, 20 Aug 2016 03:32:06 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:43232) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bb0lC-00028b-2j for 24041@debbugs.gnu.org; Sat, 20 Aug 2016 03:32:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bb0l2-0003Ak-3P for 24041@debbugs.gnu.org; Sat, 20 Aug 2016 03:32:00 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:58779) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bb0l2-0003Ag-0n; Sat, 20 Aug 2016 03:31:56 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1121 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1bb0l0-0005Cq-6i; Sat, 20 Aug 2016 03:31:54 -0400 In-reply-to: <8760qwtxld.fsf@cochranmail.com> (message from Robert Cochran on Fri, 19 Aug 2016 11:36:30 -0700) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:122406 Archived-At: > From: Robert Cochran > Date: Fri, 19 Aug 2016 11:36:30 -0700 > Cc: 24041@debbugs.gnu.org > > Anyways, so the fix here is conceptually pretty simple: have a check in > place to ensure (display-graphic-p) returns non-nil before doing any > xwidgets stuff. Easy enough. display-graphic-p accepts argument, so if a function displays on another frame or display, it should be passed that frame or display. > What I want to solicit feedback on before I write a patch is this: who > should be responsible for this check? Should the function provider (the > xwidget C 'library') check for the proper support? Or should that be > left to the user (the Lisp that calls the xwidget functions, in this > case `xwidget-webkit-browse-url`)? IMO, the check should be on the C level where the xwidget primitives are implemented. One such place is make-xwidget; maybe there are more. (The proper way of testing this on the C level is not by calling display-graphic-p, but rather with check_x_display_info.) Thanks.