aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Albinus2009-08-02 17:15:42 +0000
committerMichael Albinus2009-08-02 17:15:42 +0000
commitafae3a37773b0dfee20d04aa3bb686677b6bf757 (patch)
tree52bb8b3681ca8047739b8e7f92b7ec10102312d4
parentb9173dc296f964cab904fc5eae02344e1b59eed2 (diff)
downloademacs-afae3a37773b0dfee20d04aa3bb686677b6bf757.tar.gz
emacs-afae3a37773b0dfee20d04aa3bb686677b6bf757.zip
* net/tramp-cache.el (tramp-cache-inhibit-cache ): New defvar.
(tramp-get-file-property): Use it.
-rw-r--r--lisp/net/tramp-cache.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/net/tramp-cache.el b/lisp/net/tramp-cache.el
index 8a42a3ff746..49bbd79cb45 100644
--- a/lisp/net/tramp-cache.el
+++ b/lisp/net/tramp-cache.el
@@ -69,6 +69,9 @@
69(defvar tramp-cache-data (make-hash-table :test 'equal) 69(defvar tramp-cache-data (make-hash-table :test 'equal)
70 "Hash table for remote files properties.") 70 "Hash table for remote files properties.")
71 71
72(defvar tramp-cache-inhibit-cache nil
73 "Inhibit cache read access, when non-nil.")
74
72(defcustom tramp-persistency-file-name 75(defcustom tramp-persistency-file-name
73 (cond 76 (cond
74 ;; GNU Emacs. 77 ;; GNU Emacs.
@@ -103,7 +106,7 @@ Returns DEFAULT if not set."
103 (let* ((hash (or (gethash vec tramp-cache-data) 106 (let* ((hash (or (gethash vec tramp-cache-data)
104 (puthash vec (make-hash-table :test 'equal) 107 (puthash vec (make-hash-table :test 'equal)
105 tramp-cache-data))) 108 tramp-cache-data)))
106 (value (if (hash-table-p hash) 109 (value (if (and (null tramp-cache-inhibit-cache) (hash-table-p hash))
107 (gethash property hash default) 110 (gethash property hash default)
108 default))) 111 default)))
109 (tramp-message vec 8 "%s %s %s" file property value) 112 (tramp-message vec 8 "%s %s %s" file property value)
@@ -182,8 +185,8 @@ If the value is not set for the connection, returns DEFAULT."
182 (aset key 3 nil)) 185 (aset key 3 nil))
183 (let* ((hash (gethash key tramp-cache-data)) 186 (let* ((hash (gethash key tramp-cache-data))
184 (value (if (hash-table-p hash) 187 (value (if (hash-table-p hash)
185 (gethash property hash default) 188 (gethash property hash default)
186 default))) 189 default)))
187 (tramp-message key 7 "%s %s" property value) 190 (tramp-message key 7 "%s %s" property value)
188 value)) 191 value))
189 192