From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: "Daniel Colascione" Newsgroups: gmane.emacs.devel Subject: Re: master b9ac4f8.. (Fix locating pdump by symlink) breaks with stow Date: Mon, 24 Jun 2019 06:21:12 -0700 Message-ID: References: <87imsvuvnr.fsf@wavexx.thregr.org> <20190624111050.jindvg6j4hr5j226@Ergus> <20190624122841.vfezkecaxjqwzjy3@Ergus> Mime-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="42594"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: SquirrelMail/1.4.23 [SVN] Cc: Yuri D'Elia , Emacs developers , Yuri Khan To: "Ergus" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jun 24 15:21:28 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hfOuV-000Asv-16 for ged-emacs-devel@m.gmane.org; Mon, 24 Jun 2019 15:21:27 +0200 Original-Received: from localhost ([::1]:51128 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfOuT-0005Vs-P3 for ged-emacs-devel@m.gmane.org; Mon, 24 Jun 2019 09:21:25 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35468) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfOuM-0005Vf-Ir for emacs-devel@gnu.org; Mon, 24 Jun 2019 09:21:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfOuL-0003Vj-FK for emacs-devel@gnu.org; Mon, 24 Jun 2019 09:21:18 -0400 Original-Received: from dancol.org ([2600:3c01::f03c:91ff:fedf:adf3]:36662) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfOuK-0003TC-Lo for emacs-devel@gnu.org; Mon, 24 Jun 2019 09:21:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dancol.org; s=x; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:To:From:Subject:Date:References:In-Reply-To:Message-ID; bh=eXHM5uvDnvvR2MHSvz6PBuNLurXYDpgrUCQaWD3KNHg=; b=Dz0ex/9Q4oGnoCkVmMIQlxI9c9dFB3oNy5MTJztwvTpxmoza5TXAQxUaVfbaxbruQgW78TKlqULotszK8zFVT8EWCq66c2pbhabifBqigJSoX/x3+BNiAVJLHLQ0grBA92rYXV7YbdVlNfaWDHmzg8zlBbLxCuzTZajvzwL8OoOrEWDUvE8UQNFVJ/XE8HecfzMrSshaC6a2EyUVtoh5jJIcTHqOxeF1+ZV4TNxnHJxEHTS+CzosSSnVhVTWCAI3zwqlcP0U/HLx80n/sbCB0LCqbMaxs1/udWQu69A0Vqj+GkV4UiTV/lQrEcviUVJe9SlmAbt27n36YWurIH0hAw==; Original-Received: from localhost ([127.0.0.1] helo=dancol.org) by dancol.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfOuG-0008HD-20; Mon, 24 Jun 2019 06:21:12 -0700 Original-Received: from 127.0.0.1 (SquirrelMail authenticated user dancol) by dancol.org with HTTP; Mon, 24 Jun 2019 06:21:12 -0700 In-Reply-To: <20190624122841.vfezkecaxjqwzjy3@Ergus> X-Priority: 3 (Normal) Importance: Normal X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2600:3c01::f03c:91ff:fedf:adf3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.org gmane.emacs.devel:238093 Archived-At: > On Mon, Jun 24, 2019 at 06:57:32PM +0700, Yuri Khan wrote: >>On Mon, Jun 24, 2019 at 6:12 PM Ergus wrote: >> >>> 750| char* argv0 = realpath (argv[0], NULL); >>> 751| if (!argv0) >>> 752| fatal ("could not resolve realpath of \"%s\": %s", >>> 752| argv0, strerror (errno)); >> >>This looks wrong. If we called realpath and it returned null, we???d >>probably want the original argv[0] in the error message, not the null >>result. >> > > This also produces problems when using emacs from an alias like em o emc > which is a very common practice. > > So there should be actually other conditions to try if the first > realpath call fails and not abort (call fatal) in the first try. Try it now. Sorry about the botched change.