From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.bugs Subject: bug#8254: race condition in dired.c's scmp function Date: Tue, 15 Mar 2011 09:52:24 -0700 Organization: UCLA Computer Science Department Message-ID: <4D7F9948.5020907@cs.ucla.edu> References: <4D7F043A.5070702@cs.ucla.edu> <4D7F15E7.1020407@cs.ucla.edu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1300208839 8218 80.91.229.12 (15 Mar 2011 17:07:19 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 15 Mar 2011 17:07:19 +0000 (UTC) Cc: 8254@debbugs.gnu.org To: Juanma Barranquero Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Mar 15 18:07:14 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PzXiC-0004Rj-Ns for geb-bug-gnu-emacs@m.gmane.org; Tue, 15 Mar 2011 18:07:13 +0100 Original-Received: from localhost ([127.0.0.1]:55527 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PzXiA-00036L-Oj for geb-bug-gnu-emacs@m.gmane.org; Tue, 15 Mar 2011 13:07:10 -0400 Original-Received: from [140.186.70.92] (port=57686 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PzXi2-00033N-A5 for bug-gnu-emacs@gnu.org; Tue, 15 Mar 2011 13:07:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PzXi1-0004IJ-8A for bug-gnu-emacs@gnu.org; Tue, 15 Mar 2011 13:07:02 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:49183) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PzXi1-0004IF-5G for bug-gnu-emacs@gnu.org; Tue, 15 Mar 2011 13:07:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1PzXUT-00064s-Qa; Tue, 15 Mar 2011 12:53:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Paul Eggert Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 15 Mar 2011 16:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 8254 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 8254-submit@debbugs.gnu.org id=B8254.130020795523326 (code B ref 8254); Tue, 15 Mar 2011 16:53:01 +0000 Original-Received: (at 8254) by debbugs.gnu.org; 15 Mar 2011 16:52:35 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PzXU2-00064A-3n for submit@debbugs.gnu.org; Tue, 15 Mar 2011 12:52:34 -0400 Original-Received: from smtp.cs.ucla.edu ([131.179.128.62]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PzXTz-00063x-As for 8254@debbugs.gnu.org; Tue, 15 Mar 2011 12:52:32 -0400 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp.cs.ucla.edu (Postfix) with ESMTP id 90F1839E80FF; Tue, 15 Mar 2011 09:52:25 -0700 (PDT) X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu Original-Received: from smtp.cs.ucla.edu ([127.0.0.1]) by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Nqbr8rgPQklL; Tue, 15 Mar 2011 09:52:25 -0700 (PDT) Original-Received: from [131.179.64.200] (Penguin.CS.UCLA.EDU [131.179.64.200]) by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 19CE239E80E1; Tue, 15 Mar 2011 09:52:25 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Thunderbird/3.1.7 In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Tue, 15 Mar 2011 12:53:01 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:45038 Archived-At: On 03/15/2011 04:36 AM, Juanma Barranquero wrote: > there's adding complexity when it is not needed. The patch subtracts complexity in one place (by removing global variables) and adds it in another (by creating static inline functions). Whether the overall effect is to decrease complexity, or to increase it, is debatable. Either way, it's not much of a change in complexity. There are efforts underway to make Emacs multithreaded. If that happens, a change like this will be needed, as the existing code is obviously not thread-safe. I don't see any real downside to installing this change in the trunk now. > A (perhaps stupid) idea: would it be possible to define > -DENABLE-CHECKING alternate versions of DOWNCASE and UPCASE1 which do > some additional checking for side effects? I plan to implement that sort of suggestion, but in a different way, by adding an --enable-gcc-warnings option to 'configure', which will cause it to pass extra options to GCC to catch this sort of problem. This option is already in used in several other projects, such as GNU coreutils, and Emacs would benefit from it as well. The option will be disabled by default, though, so that the warnings don't surprise people who don't expect them.