diff lisp/prim/files.el @ 24:4103f0995bd7 r19-15b95

Import from CVS: tag r19-15b95
author cvs
date Mon, 13 Aug 2007 08:51:03 +0200
parents 8fc7fe29b841
children 441bb1e64a06
line wrap: on
line diff
--- a/lisp/prim/files.el	Mon Aug 13 08:50:31 2007 +0200
+++ b/lisp/prim/files.el	Mon Aug 13 08:51:03 2007 +0200
@@ -144,8 +144,9 @@
 nil means make them for files that have some already.
 `never' means do not make them.")
 
-(defvar dired-kept-versions 2
-  "*When cleaning directory, number of versions to keep.")
+;; This is now defined in efs.
+;(defvar dired-kept-versions 2
+;  "*When cleaning directory, number of versions to keep.")
 
 (defvar delete-old-versions nil
   "*If t, delete excess backup versions silently.
@@ -1238,6 +1239,7 @@
               ))))))
 
 ;; XEmacs: this function is not synched with FSF
+;; jwz - New Version 20.1/19.15
 (defun hack-local-variables-prop-line (&optional force)
   ;; Set local variables specified in the -*- line.
   ;; Returns t if mode was set.
@@ -1258,7 +1260,7 @@
 	;; Parse the -*- line into the `result' alist.
 	(cond ((not (search-forward "-*-" end t))
 	       ;; doesn't have one.
-	       (setq force t))
+	       nil)
 	      ((looking-at "[ \t]*\\([^ \t\n\r:;]+\\)\\([ \t]*-\\*-\\)")
 	       ;; Antiquated form: "-*- ModeName -*-".
 	       (setq result
@@ -1294,22 +1296,21 @@
 		   (skip-chars-forward " \t;")))
 	       (setq result (nreverse result))))))
 	
-    (if result
-	(let ((set-any-p (or force (hack-local-variables-p t)))
-	      (mode-p nil))
-	  (while result
-	    (let ((key (car (car result)))
-		  (val (cdr (car result))))
-	      (cond ((eq key 'mode)
-		     (setq mode-p t)
-		     (funcall (intern (concat (downcase (symbol-name val))
-					      "-mode"))))
-		    (set-any-p
-		     (hack-one-local-variable key val))
-		    (t
-		     nil)))
-	    (setq result (cdr result)))
-	  mode-p))))
+    (let ((set-any-p (or force (hack-local-variables-p t)))
+	  (mode-p nil))
+      (while result
+	(let ((key (car (car result)))
+	      (val (cdr (car result))))
+	  (cond ((eq key 'mode)
+		 (setq mode-p t)
+		 (funcall (intern (concat (downcase (symbol-name val))
+					  "-mode"))))
+		(set-any-p
+		 (hack-one-local-variable key val))
+		(t
+		 nil)))
+	(setq result (cdr result)))
+      mode-p)))
 
 (defvar hack-local-variables-hook nil
   "Normal hook run after processing a file's local variables specs.
@@ -3011,9 +3012,9 @@
   "Test whether file resides on the local system.
 The special value 'unknown is returned if no remote file access package
 has been loaded."
-  (cond ((fboundp 'efs-ftp-path) (efs-ftp-path name))
-	((fboundp 'ange-ftp-ftp-name) (ange-ftp-ftp-name name))
-	(t 'unknown)))
+  (cond ((featurep 'ange-ftp) (ange-ftp-ftp-path file-name))
+        (t (require 'efs)
+	   (efs-ftp-path file-name))))
 
 ;; Written in C in FSF
 (defun insert-file-contents (filename &optional visit beg end replace)