diff options
| author | Michael Albinus | 2019-06-15 11:46:04 +0200 |
|---|---|---|
| committer | Michael Albinus | 2019-06-15 11:46:04 +0200 |
| commit | e1867056ae7ef3ffce90d4b2564a9e81b54818ba (patch) | |
| tree | 045b77b2be9f3c720c3349ef621cafabfc92d77d | |
| parent | 55cdebcf63644dbd8cd53618438b96fe9b70022b (diff) | |
| download | emacs-e1867056ae7ef3ffce90d4b2564a9e81b54818ba.tar.gz emacs-e1867056ae7ef3ffce90d4b2564a9e81b54818ba.zip | |
Let tramp-archive unmount clean
* lisp/net/tramp-archive.el (tramp-archive-cleanup-hash):
Don't check for a proper method.
| -rw-r--r-- | lisp/net/tramp-archive.el | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/lisp/net/tramp-archive.el b/lisp/net/tramp-archive.el index e6ae73aae61..d7f99667f45 100644 --- a/lisp/net/tramp-archive.el +++ b/lisp/net/tramp-archive.el | |||
| @@ -475,17 +475,19 @@ name is kept in slot `hop'" | |||
| 475 | 475 | ||
| 476 | (defun tramp-archive-cleanup-hash () | 476 | (defun tramp-archive-cleanup-hash () |
| 477 | "Remove local copies of archives, used by GVFS." | 477 | "Remove local copies of archives, used by GVFS." |
| 478 | (maphash | 478 | ;; Don't check for a proper method. |
| 479 | (lambda (key value) | 479 | (let ((non-essential t)) |
| 480 | ;; Unmount local copy. | 480 | (maphash |
| 481 | (ignore-errors | 481 | (lambda (key value) |
| 482 | (tramp-message (car value) 3 "Unmounting %s" (or (cdr value) key)) | 482 | ;; Unmount local copy. |
| 483 | (tramp-gvfs-unmount (car value))) | 483 | (ignore-errors |
| 484 | ;; Delete local copy. | 484 | (tramp-message (car value) 3 "Unmounting %s" (or (cdr value) key)) |
| 485 | (ignore-errors (delete-file (cdr value))) | 485 | (tramp-gvfs-unmount (car value))) |
| 486 | (remhash key tramp-archive-hash)) | 486 | ;; Delete local copy. |
| 487 | tramp-archive-hash) | 487 | (ignore-errors (delete-file (cdr value))) |
| 488 | (clrhash tramp-archive-hash)) | 488 | (remhash key tramp-archive-hash)) |
| 489 | tramp-archive-hash) | ||
| 490 | (clrhash tramp-archive-hash))) | ||
| 489 | 491 | ||
| 490 | (add-hook 'tramp-cleanup-all-connections-hook #'tramp-archive-cleanup-hash) | 492 | (add-hook 'tramp-cleanup-all-connections-hook #'tramp-archive-cleanup-hash) |
| 491 | (add-hook 'kill-emacs-hook #'tramp-archive-cleanup-hash) | 493 | (add-hook 'kill-emacs-hook #'tramp-archive-cleanup-hash) |