From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ihor Radchenko Newsgroups: gmane.emacs.bugs Subject: bug#68976: 30.0.50; Tramp: unexpected error when calling (file-remote-p "/dav:localhost#8000:/foo") Date: Wed, 07 Feb 2024 19:07:02 +0000 Message-ID: <877cjgqejt.fsf@localhost> References: <87eddo45qj.fsf@localhost> <87fry4b1ez.fsf@gmx.de> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22851"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 68976@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Feb 07 20:04:23 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rXnDb-0005jq-4M for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 07 Feb 2024 20:04:23 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXnD5-0007B2-NI; Wed, 07 Feb 2024 14:03:51 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXnD2-0007Am-K2 for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 14:03:48 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXnD2-00087T-CD for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 14:03:48 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rXnDF-0006e6-UN for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 14:04:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Ihor Radchenko Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 07 Feb 2024 19:04:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68976 X-GNU-PR-Package: emacs Original-Received: via spool by 68976-submit@debbugs.gnu.org id=B68976.170733263425527 (code B ref 68976); Wed, 07 Feb 2024 19:04:01 +0000 Original-Received: (at 68976) by debbugs.gnu.org; 7 Feb 2024 19:03:54 +0000 Original-Received: from localhost ([127.0.0.1]:57934 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXnD7-0006df-OF for submit@debbugs.gnu.org; Wed, 07 Feb 2024 14:03:54 -0500 Original-Received: from mout01.posteo.de ([185.67.36.65]:33485) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXnD4-0006dR-UA for 68976@debbugs.gnu.org; Wed, 07 Feb 2024 14:03:52 -0500 Original-Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id B6226240027 for <68976@debbugs.gnu.org>; Wed, 7 Feb 2024 20:03:30 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1707332610; bh=SqxPIowGb9vcAfbAQN2RCOQBKwAgYbtODVYmRPipoQg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=bEelSdEAz/nj9TQlH8jnhiRK9pui0JNCt60zDqRQZAHxa5FXvOvPXRaLPiLRYgRRj KDl1G+ZXyp5QkyhuGFOH/viMk6s0qG8NBJ57q4PNbkeCio+6aOvtCyjXUuB2CVAyVA Jp4ik/4XXlRWFh9XwJ8KLp2cOwiNzS6sExJSHsaJ9MnL0ECPFBLPApFu241KmjV+dB 6Xe3aWn/jqEblQBL29wBSnxRFXhekH7s4PnDKOTNPRrDxZkKzIBP9RGmxAbZEjRrD5 X0jDUGRfdG1t7L14qPxohpgCem3WWIQZs48Gua82hkKD2GYIXEAfz4B1HjvRRM9GaS vwgXMb65rxDrQ== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TVTzP6Ryhz9rxF; Wed, 7 Feb 2024 20:03:29 +0100 (CET) In-Reply-To: <87fry4b1ez.fsf@gmx.de> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:279577 Archived-At: Michael Albinus writes: > You are right. It should have returned nil instead of the > error. `file-remote-p' claims in its docstring > ... > --8<---------------cut here---------------start------------->8--- > Test whether FILE specifies a location on a remote system. > --8<---------------cut here---------------end--------------->8--- > ... > > If you want to know, whether a file name has remote file name syntax, > you should call > > (string-match-p tramp-file-name-regexp "/dav:localhost#8000:/foo") > > This variable is documented in the Tramp manual, node "(tramp) Change > file name syntax". Are you saying that I shouldn't use `file-remote-p'? For me, the goal is to determine whether file is coming from trusted place or not. By default, anything non-local (Urls, TRAMP paths, etc) should not be trusted. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at