From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: [Emacs-diffs] master 8ba156f: Attempt to avoid crashes in plist-member Date: Tue, 13 Oct 2015 17:58:42 +0300 Message-ID: <83io6azufx.fsf@gnu.org> References: <20151012170324.17966.77@vcs.savannah.gnu.org> <83k2qro5eg.fsf@gnu.org> <561C7C26.3060408@cs.ucla.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1444748483 22524 80.91.229.3 (13 Oct 2015 15:01:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 13 Oct 2015 15:01:23 +0000 (UTC) Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org To: Paul Eggert Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Oct 13 17:01:14 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Zm14j-0001cl-9V for ged-emacs-devel@m.gmane.org; Tue, 13 Oct 2015 17:01:13 +0200 Original-Received: from localhost ([::1]:36591 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zm14i-0004bV-5q for ged-emacs-devel@m.gmane.org; Tue, 13 Oct 2015 11:01:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35418) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zm13W-0003Jy-2D for emacs-devel@gnu.org; Tue, 13 Oct 2015 11:00:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zm13S-0003Aj-1B for emacs-devel@gnu.org; Tue, 13 Oct 2015 10:59:57 -0400 Original-Received: from mtaout25.012.net.il ([80.179.55.181]:57193) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zm13R-0003A6-PT for emacs-devel@gnu.org; Tue, 13 Oct 2015 10:59:53 -0400 Original-Received: from conversion-daemon.mtaout25.012.net.il by mtaout25.012.net.il (HyperSendmail v2007.08) id <0NW500I00YJW2100@mtaout25.012.net.il> for emacs-devel@gnu.org; Tue, 13 Oct 2015 17:55:59 +0300 (IDT) Original-Received: from HOME-C4E4A596F7 ([84.94.185.246]) by mtaout25.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NW5009NJYTBKB90@mtaout25.012.net.il>; Tue, 13 Oct 2015 17:55:59 +0300 (IDT) In-reply-to: <561C7C26.3060408@cs.ucla.edu> X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 80.179.55.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:191464 Archived-At: > Cc: emacs-devel@gnu.org > From: Paul Eggert > Date: Mon, 12 Oct 2015 20:36:06 -0700 > > QUIT could call some Lisp. > > Sure, but Lisp cannot affect the value of CONSP (plist). Not the value of CONSP, the list itself. We follow the CONSP test with XCAR, which crashed. The only way I could imagine that happening is that the list got modified between the test and the XCAR call. Is there any other way to explain that? > How else would you explain a segfault in that loop? > > It's not clear the code is in that loop. The address clearly points to Fplist_member at fns.c:2879. > It could merely be RtlCaptureStackBackTrace misbehaving, no? I don't think so. It could be something else, though: the segfault could have happened in another thread while the Lisp thread was in plist-member. But the change I made cannot do any harm, and it tried to use the only evidence I had from the report. The alternative was to do nothing at all.