From unknown Tue Jun 17 03:39:39 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#23089 <23089@debbugs.gnu.org> To: bug#23089 <23089@debbugs.gnu.org> Subject: Status: 25.0.92; dired-goto-file in `find-dired' buffers Reply-To: bug#23089 <23089@debbugs.gnu.org> Date: Tue, 17 Jun 2025 10:39:39 +0000 retitle 23089 25.0.92; dired-goto-file in `find-dired' buffers reassign 23089 emacs submitter 23089 Tino Calancha severity 23089 minor thanks From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 22 07:19:54 2016 Received: (at submit) by debbugs.gnu.org; 22 Mar 2016 11:19:54 +0000 Received: from localhost ([127.0.0.1]:57773 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aiKLq-0005yT-9i for submit@debbugs.gnu.org; Tue, 22 Mar 2016 07:19:54 -0400 Received: from eggs.gnu.org ([208.118.235.92]:45992) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aiKLp-0005yH-5W for submit@debbugs.gnu.org; Tue, 22 Mar 2016 07:19:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aiKLg-0006Xd-RS for submit@debbugs.gnu.org; Tue, 22 Mar 2016 07:19:47 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_40,FREEMAIL_FROM autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:40984) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aiKLg-0006XY-No for submit@debbugs.gnu.org; Tue, 22 Mar 2016 07:19:44 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36938) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aiKLa-0002WV-Ur for bug-gnu-emacs@gnu.org; Tue, 22 Mar 2016 07:19:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aiKLX-0006Qx-Ng for bug-gnu-emacs@gnu.org; Tue, 22 Mar 2016 07:19:38 -0400 Received: from calancha-ilc.kek.jp ([130.87.234.234]:34815) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aiKLX-0006Qo-DN for bug-gnu-emacs@gnu.org; Tue, 22 Mar 2016 07:19:35 -0400 Received: by calancha-ilc.kek.jp (Postfix, from userid 500) id 2EB6ED99C; Tue, 22 Mar 2016 20:22:51 +0900 (JST) Received: from localhost (localhost [127.0.0.1]) by calancha-ilc.kek.jp (Postfix) with ESMTP id C3ABC54C0 for ; Tue, 22 Mar 2016 20:22:51 +0900 (JST) Date: Tue, 22 Mar 2016 20:22:51 +0900 (JST) From: Tino Calancha X-X-Sender: calancha@calancha-ilc.kek.jp To: bug-gnu-emacs@gnu.org Subject: 25.0.92; dired-goto-file in `find-dired' buffers Message-ID: User-Agent: Alpine 2.20 (LRH 67 2015-01-07) MIME-Version: 1.0 Content-Type: multipart/mixed; BOUNDARY="1468197610-1901859976-1458645771=:11552" X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) --1468197610-1901859976-1458645771=:11552 Content-Type: text/plain; format=flowed; charset=US-ASCII Dired buffers output from `find-dired' commands, usually contains filename including '/'. Command `dired-goto-file' fails on those files. ; emacs-lisp: emacs -Q $emacs-lisp M-x find-name-dired RET *.el RET j language/thai-word.el RET ;It cannot find the file. In GNU Emacs 25.0.92.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.30) of 2016-03-22 built on calancha-pc Repository revision: dbfbedd3d0f3afcfb811eae0e1a7b1c33fb27735 --1468197610-1901859976-1458645771=:11552 Content-Type: text/plain; charset=US-ASCII; name=dired.patch Content-Transfer-Encoding: BASE64 Content-ID: Content-Description: Content-Disposition: attachment; filename=dired.patch ZGlmZiAtLWdpdCBhL2xpc3AvZGlyZWQuZWwgYi9saXNwL2RpcmVkLmVsDQpp bmRleCAyNGIxMjhmLi4zYzY2YThlIDEwMDY0NA0KLS0tIGEvbGlzcC9kaXJl ZC5lbA0KKysrIGIvbGlzcC9kaXJlZC5lbA0KQEAgLTI3NDYsNyArMjc0Niwy MCBAQCBkaXJlZC1nb3RvLWZpbGUNCiAJCQkJKGRpcmVkLWdvdG8tc3ViZGly IGRpcikpKQ0KIAkJICAgICAoZGlyZWQtZ290by1maWxlLTEgKGZpbGUtbmFt ZS1ub25kaXJlY3RvcnkgZmlsZSkNCiAJCQkJCWZpbGUNCi0JCQkJCShkaXJl ZC1zdWJkaXItbWF4KSkpKSkpKQ0KKwkJCQkJKGRpcmVkLXN1YmRpci1tYXgp KSkpDQorCQkgOzsgSGFuZGxlIERpcmVkIGJ1ZmZlcnMgZnJvbSBgZmluZC1k aXJlZCcgY29tbWFuZHMuICBUaGUNCisJCSA7OyBmaWxlbmFtZSBpbmNsdWRl cyAnLycgaWYgdGhlIGZpbGUgYmVsb25ncyB0byBhIHN1YmRpcg0KKwkJIDs7 IG9mIGBkZWZhdWx0LWRpcmVjdG9yeScuDQorCQkgKHNhdmUtZXhjdXJzaW9u DQorCQkgICAobGV0ICgobmFtZS1sZW4gICAobGVuZ3RoIGZpbGUpKQ0KKwkJ CQkgKGRlZmRpci1sZW4gKGxlbmd0aCAoZXhwYW5kLWZpbGUtbmFtZSBkZWZh dWx0LWRpcmVjdG9yeSkpKSkNCisJCQkgKGdvdG8tY2hhciAocG9pbnQtbWlu KSkNCisJCQkgKGFuZCAobm90IChjZHIgZGlyZWQtc3ViZGlyLWFsaXN0KSkN CisJCQkJICAoPiBuYW1lLWxlbiBkZWZkaXItbGVuKQ0KKwkJCQkgIChkaXJl ZC1nb3RvLWZpbGUtMSAoc3Vic3RyaW5nIGZpbGUgZGVmZGlyLWxlbikNCisJ CQkJCQkJCQkgZmlsZQ0KKwkJCQkJCQkJCSAocG9pbnQtbWF4KSkpKSkpKSkN CisNCiAgICAgOzsgUmV0dXJuIGJ1ZmZlciBwb3NpdGlvbiwgaWYgZm91bmQu DQogICAgIChpZiBmb3VuZA0KIAkoZ290by1jaGFyIGZvdW5kKSkpKQ0K --1468197610-1901859976-1458645771=:11552-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 25 04:39:36 2016 Received: (at 23089) by debbugs.gnu.org; 25 Mar 2016 08:39:36 +0000 Received: from localhost ([127.0.0.1]:36810 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajNHM-0006c6-GH for submit@debbugs.gnu.org; Fri, 25 Mar 2016 04:39:36 -0400 Received: from eggs.gnu.org ([208.118.235.92]:56598) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajNHK-0006bs-NE for 23089@debbugs.gnu.org; Fri, 25 Mar 2016 04:39:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ajNH7-0001QY-6k for 23089@debbugs.gnu.org; Fri, 25 Mar 2016 04:39:29 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:40646) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ajNH7-0001QI-3l; Fri, 25 Mar 2016 04:39:21 -0400 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4581 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1ajNH6-0006vi-Kr; Fri, 25 Mar 2016 04:39:20 -0400 Date: Fri, 25 Mar 2016 11:39:15 +0300 Message-Id: <83r3ez0x58.fsf@gnu.org> From: Eli Zaretskii To: Tino Calancha In-reply-to: (message from Tino Calancha on Tue, 22 Mar 2016 20:22:51 +0900 (JST)) Subject: Re: bug#23089: 25.0.92; dired-goto-file in `find-dired' buffers References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 23089 Cc: 23089@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) > Date: Tue, 22 Mar 2016 20:22:51 +0900 (JST) > From: Tino Calancha > > Dired buffers output from `find-dired' commands, usually contains > filename including '/'. Command `dired-goto-file' fails > on those files. > > ; emacs-lisp: > emacs -Q $emacs-lisp > M-x find-name-dired RET *.el RET > j language/thai-word.el RET > > ;It cannot find the file. Thanks for the report and the patch. Does the alternative patch below look correct, and does it give good results? diff --git a/lisp/dired.el b/lisp/dired.el index ef22d45..5741872 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -2736,9 +2736,18 @@ dired-goto-file (save-excursion (goto-char (point-min)) (dired-goto-file-1 file file (point-max))) - ;; Otherwise, look for it as a relative name. The - ;; hair is to get the result of `dired-goto-subdir' - ;; without calling it if we don't have any subdirs. + ;; Next, look for it as a relative name with leading + ;; subdirectories. (This happens in Dired buffers + ;; created by find-dired, for example.) + (save-excursion + (goto-char (point-min)) + (dired-goto-file-1 (file-relative-name file + default-directory) + file (point-max))) + ;; Otherwise, look for it as a relative name, a base + ;; name only. The hair is to get the result of + ;; `dired-goto-subdir' without calling it if we don't + ;; have any subdirs. (save-excursion (when (if (string= dir (expand-file-name default-directory)) (goto-char (point-min)) From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 25 07:18:01 2016 Received: (at 23089) by debbugs.gnu.org; 25 Mar 2016 11:18:02 +0000 Received: from localhost ([127.0.0.1]:36928 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajPkf-0005bY-Jj for submit@debbugs.gnu.org; Fri, 25 Mar 2016 07:18:01 -0400 Received: from calancha-ilc.kek.jp ([130.87.234.234]:36908) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajPkc-0005bF-RX for 23089@debbugs.gnu.org; Fri, 25 Mar 2016 07:17:59 -0400 Received: by calancha-ilc.kek.jp (Postfix, from userid 500) id C3F2795C5; Fri, 25 Mar 2016 20:21:06 +0900 (JST) Received: from localhost (localhost [127.0.0.1]) by calancha-ilc.kek.jp (Postfix) with ESMTP id ACFDF3F5E; Fri, 25 Mar 2016 20:21:06 +0900 (JST) Date: Fri, 25 Mar 2016 20:21:06 +0900 (JST) From: Tino Calancha X-X-Sender: calancha@calancha-ilc.kek.jp To: Eli Zaretskii Subject: Re: bug#23089: 25.0.92; dired-goto-file in `find-dired' buffers In-Reply-To: <83r3ez0x58.fsf@gnu.org> Message-ID: References: <83r3ez0x58.fsf@gnu.org> User-Agent: Alpine 2.20 (LRH 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: 23089 Cc: Tino Calancha , 23089@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.0 (+) > Does the alternative patch below > look correct, and does it give good results? Yes, your alternative patch also fix the problem, and it's more elegant. From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 25 10:20:30 2016 Received: (at 23089-done) by debbugs.gnu.org; 25 Mar 2016 14:20:30 +0000 Received: from localhost ([127.0.0.1]:37960 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajSbG-0005DN-0r for submit@debbugs.gnu.org; Fri, 25 Mar 2016 10:20:30 -0400 Received: from eggs.gnu.org ([208.118.235.92]:54793) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajSbD-0005DA-Te for 23089-done@debbugs.gnu.org; Fri, 25 Mar 2016 10:20:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ajSb3-0001V8-Rc for 23089-done@debbugs.gnu.org; Fri, 25 Mar 2016 10:20:22 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:57080) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ajSb3-0001V4-OV; Fri, 25 Mar 2016 10:20:17 -0400 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4874 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1ajSb3-0007zS-1I; Fri, 25 Mar 2016 10:20:17 -0400 Date: Fri, 25 Mar 2016 17:20:02 +0300 Message-Id: <838u161vxp.fsf@gnu.org> From: Eli Zaretskii To: Tino Calancha In-reply-to: (message from Tino Calancha on Fri, 25 Mar 2016 20:21:06 +0900 (JST)) Subject: Re: bug#23089: 25.0.92; dired-goto-file in `find-dired' buffers References: <83r3ez0x58.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -6.0 (------) X-Debbugs-Envelope-To: 23089-done Cc: 23089-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Fri, 25 Mar 2016 20:21:06 +0900 (JST) > From: Tino Calancha > cc: Tino Calancha , 23089@debbugs.gnu.org > > > Does the alternative patch below > > look correct, and does it give good results? > Yes, your alternative patch also fix the problem, and it's more elegant. Thanks, I pushed it to emacs-25 branch. From unknown Tue Jun 17 03:39:39 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 23 Apr 2016 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator