From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#12908: 24.3.50; file `emacs_backtrace.txt'? Date: Sat, 17 Nov 2012 21:09:27 +0200 Message-ID: <8339082gig.fsf@gnu.org> References: <4B9EFDFEE27E43DBB6331605DD7C2842@us.oracle.com> <50A7DB2C.7050501@cs.ucla.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1353179425 28758 80.91.229.3 (17 Nov 2012 19:10:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 17 Nov 2012 19:10:25 +0000 (UTC) Cc: 12908@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Nov 17 20:10:35 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1TZnmc-0008GM-2d for geb-bug-gnu-emacs@m.gmane.org; Sat, 17 Nov 2012 20:10:26 +0100 Original-Received: from localhost ([::1]:60115 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TZnmR-0000FZ-Qj for geb-bug-gnu-emacs@m.gmane.org; Sat, 17 Nov 2012 14:10:15 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:45224) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TZnmN-0000Dl-Gk for bug-gnu-emacs@gnu.org; Sat, 17 Nov 2012 14:10:14 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TZnmK-0004pe-Ep for bug-gnu-emacs@gnu.org; Sat, 17 Nov 2012 14:10:11 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:41035) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TZnmK-0004pa-B9 for bug-gnu-emacs@gnu.org; Sat, 17 Nov 2012 14:10:08 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TZnnB-0001T6-Mk for bug-gnu-emacs@gnu.org; Sat, 17 Nov 2012 14:11:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 17 Nov 2012 19:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 12908 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 12908-submit@debbugs.gnu.org id=B12908.13531794545629 (code B ref 12908); Sat, 17 Nov 2012 19:11:01 +0000 Original-Received: (at 12908) by debbugs.gnu.org; 17 Nov 2012 19:10:54 +0000 Original-Received: from localhost ([127.0.0.1]:51286 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TZnn3-0001Sj-O0 for submit@debbugs.gnu.org; Sat, 17 Nov 2012 14:10:54 -0500 Original-Received: from mtaout21.012.net.il ([80.179.55.169]:57988) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TZnn0-0001SX-UX for 12908@debbugs.gnu.org; Sat, 17 Nov 2012 14:10:52 -0500 Original-Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0MDN00A00BOIOG00@a-mtaout21.012.net.il> for 12908@debbugs.gnu.org; Sat, 17 Nov 2012 21:09:55 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MDN00A9YBWJ6CP0@a-mtaout21.012.net.il>; Sat, 17 Nov 2012 21:09:55 +0200 (IST) In-reply-to: <50A7DB2C.7050501@cs.ucla.edu> X-012-Sender: halo1@inter.net.il X-Spam-Score: 1.5 (+) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-Spam-Score: 1.5 (+) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x 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: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:67071 Archived-At: > Date: Sat, 17 Nov 2012 10:45:00 -0800 > From: Paul Eggert > > There seems to be some misunderstanding here. The Unix code does > not write into $HOME/backtrace.txt, or into $HOME, or into anywhere > like that. It writes to stderr. The programs that invoke Emacs > (normally window managers) arrange for the standard error stream > to be sent to a suitable place. That suitable place is in a subdirectory of the user's home directory, at least on the most popular systems, according to the Emacs manual. > The Microsoft Windows code does something different: it writes the > backtrace both to stderr and to a file emacs_backtrace.txt. Yes. > If the goal is to mimic the Unix behavior as closely as possible, then > the fix should be simple: output the backtrace just to stderr, as > the Unix code does. This will not work: unlike Unix, a GUI program invoked on Windows from a desktop icon normally has its standard error stream closed. So writing there will end up nowhere. That is why my implementation writes both to stderr and to the file; in the worst (or best?) case, you have two copies of the information, but you always have at least one. > Perhaps there are reasons not to do that on Microsoft Windows, but > as these reasons are specific to that platform it would seem that > any fix would be platform-specific as well. I don't see it that way. If what the Unix code writes to stderr ends up in some random location under the user's home directory, or even in a place whose whereabouts no one knows, then I see no reason not to write it on Windows in the current directory of the Emacs process. (Note that unlike on Unix, Emacs on Windows doesn't change its current directory from where it was started, so the backtrace will normally end up in the same directory for all invocations of Emacs on that machine by that user.) If we want the information in .emacs.d, we need to actively write it there on Unix.