[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master e6c6486: Tramp cache fixes
From: |
Michael Albinus |
Subject: |
master e6c6486: Tramp cache fixes |
Date: |
Sat, 28 Mar 2020 07:59:11 -0400 (EDT) |
branch: master
commit e6c6486ee0b4e50c61c062f475bbe473cfd397f9
Author: Michael Albinus <address@hidden>
Commit: Michael Albinus <address@hidden>
Tramp cache fixes
* lisp/net/tramp-adb.el (tramp-adb-handle-write-region):
* lisp/net/tramp-smb.el (tramp-smb-handle-write-region): Flush the
cache after the file has been written.
---
lisp/net/tramp-adb.el | 7 ++++---
lisp/net/tramp-smb.el | 7 ++++---
2 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/lisp/net/tramp-adb.el b/lisp/net/tramp-adb.el
index bfeaeba..4512179 100644
--- a/lisp/net/tramp-adb.el
+++ b/lisp/net/tramp-adb.el
@@ -629,9 +629,6 @@ But handle the case, if the \"test\" command is not
available."
(format "File %s exists; overwrite anyway? " filename)))))
(tramp-error v 'file-already-exists filename))
- ;; We must also flush the cache of the directory, because
- ;; `file-attributes' reads the values from there.
- (tramp-flush-file-properties v localname)
(let* ((curbuf (current-buffer))
(tmpfile (tramp-compat-make-temp-file filename)))
(when (and append (file-exists-p filename))
@@ -648,6 +645,10 @@ But handle the case, if the \"test\" command is not
available."
(tramp-error v 'file-error "Cannot write: `%s'" filename))
(delete-file tmpfile)))
+ ;; We must also flush the cache of the directory, because
+ ;; `file-attributes' reads the values from there.
+ (tramp-flush-file-properties v localname)
+
(unless (equal curbuf (current-buffer))
(tramp-error
v 'file-error
diff --git a/lisp/net/tramp-smb.el b/lisp/net/tramp-smb.el
index effac33..100ddfa 100644
--- a/lisp/net/tramp-smb.el
+++ b/lisp/net/tramp-smb.el
@@ -1557,9 +1557,6 @@ errors for shares like \"C$/\", which are common in
Microsoft Windows."
(format "File %s exists; overwrite anyway? " filename)))))
(tramp-error v 'file-already-exists filename))
- ;; We must also flush the cache of the directory, because
- ;; `file-attributes' reads the values from there.
- (tramp-flush-file-properties v localname)
(let ((curbuf (current-buffer))
(tmpfile (tramp-compat-make-temp-file filename)))
(when (and append (file-exists-p filename))
@@ -1579,6 +1576,10 @@ errors for shares like \"C$/\", which are common in
Microsoft Windows."
(tramp-error v 'file-error "Cannot write `%s'" filename))
(delete-file tmpfile)))
+ ;; We must also flush the cache of the directory, because
+ ;; `file-attributes' reads the values from there.
+ (tramp-flush-file-properties v localname)
+
(unless (equal curbuf (current-buffer))
(tramp-error
v 'file-error
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master e6c6486: Tramp cache fixes,
Michael Albinus <=