emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/files.el,v


From: Michael Albinus
Subject: [Emacs-diffs] Changes to emacs/lisp/files.el,v
Date: Sun, 08 Jul 2007 18:03:21 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Michael Albinus <albinus>       07/07/08 18:03:20

Index: files.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/files.el,v
retrieving revision 1.909
retrieving revision 1.910
diff -u -b -r1.909 -r1.910
--- files.el    7 Jul 2007 05:28:27 -0000       1.909
+++ files.el    8 Jul 2007 18:03:18 -0000       1.910
@@ -727,17 +727,23 @@
                          (cons load-path (get-load-suffixes)))))
   (load library))
 
-(defun file-remote-p (file)
+(defun file-remote-p (file &optional connected)
   "Test whether FILE specifies a location on a remote system.
 Return an identification of the system if the location is indeed
 remote.  The identification of the system may comprise a method
 to access the system and its hostname, amongst other things.
 
 For example, the filename \"/address@hidden:/foo\" specifies a location
-on the system \"/address@hidden:\"."
+on the system \"/address@hidden:\".
+
+If CONNECTED is non-nil, the function returns an identification only
+if FILE is located on a remote system, and a connection is established
+to that remote system.
+
+`file-remote-p' will never open a connection on its own."
   (let ((handler (find-file-name-handler file 'file-remote-p)))
     (if handler
-       (funcall handler 'file-remote-p file)
+       (funcall handler 'file-remote-p file connected)
       nil)))
 
 (defun file-local-copy (file)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]