diff options
| author | Michael Albinus | 2020-06-14 15:31:17 +0200 |
|---|---|---|
| committer | Michael Albinus | 2020-06-14 15:31:17 +0200 |
| commit | b3e7d046c3a94556fcaf6f9ce72aa2ecb20262a6 (patch) | |
| tree | c70f1f11e7fd7f34dfd836bb5da3aa1059562e05 /test | |
| parent | 82a632edc8b80bf16d9b9f205474bf9724b084c0 (diff) | |
| download | emacs-b3e7d046c3a94556fcaf6f9ce72aa2ecb20262a6.tar.gz emacs-b3e7d046c3a94556fcaf6f9ce72aa2ecb20262a6.zip | |
Rearrange detecting remote uid and gid in Tramp
* lisp/net/tramp-adb.el (tramp-adb-file-name-handler-alist):
* lisp/net/tramp-archive.el (tramp-archive-file-name-handler-alist):
* lisp/net/tramp-rclone.el (tramp-rclone-file-name-handler-alist):
* lisp/net/tramp-smb.el (tramp-smb-file-name-handler-alist):
Add `tramp-get-remote-gid' and 'tramp-get-remote-uid'.
* lisp/net/tramp-crypt.el (tramp-crypt-file-name-handler-alist):
Add `file-ownership-preserved-p'.
(tramp-crypt-add-directory): Check, that NAME is not quoted.
(tramp-crypt-handle-file-ownership-preserved-p): New defun.
(tramp-crypt-handle-insert-directory): Fix docstring.
* lisp/net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist):
Add `tramp-get-remote-gid' and 'tramp-get-remote-uid'.
(tramp-gvfs-handle-file-readable-p): Call `tramp-get-remote-uid'.
(tramp-gvfs-handle-get-remote-uid)
(tramp-gvfs-handle-get-remote-gid): Rename from
`tramp-gvfs-get-remote-{uid,gid}'. Do not cache result.
(tramp-gvfs-maybe-open-connection): No special handling for remote
uid and gid.
* lisp/net/tramp-sh.el (tramp-sh-file-name-handler-alist):
Add `tramp-get-remote-gid' and 'tramp-get-remote-uid'.
(tramp-sh-handle-get-remote-uid, tramp-sh-handle-get-remote-gid):
Rename from `tramp-get-remote-{uid,gid}'. Do not cache result.
(tramp-sh-handle-file-ownership-preserved-p): Distinguish by GROUP
when caching.
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-file-name-handler-alist):
Add `tramp-get-remote-gid' and 'tramp-get-remote-uid'.
(tramp-sudoedit-handle-get-remote-uid)
(tramp-sudoedit-handle-get-remote-gid): Rename from
`tramp-sudoedit-get-remote-{uid,gid}'. Do not cache result.
(tramp-sudoedit-handle-set-file-uid-gid)
(tramp-sudoedit-handle-write-region): Call `tramp-get-remote-uid'
and `tramp-get-remote-gid'.
(tramp-sudoedit-maybe-open-connection): No special handling for
remote uid and gid.
* lisp/net/tramp.el (tramp-file-name-for-operation):
Add `tramp-get-remote-gid' and 'tramp-get-remote-uid'.
(tramp-handle-write-region, tramp-check-cached-permissions):
Call `tramp-get-remote-uid' and `tramp-get-remote-gid'.
(tramp-get-remote-uid, tramp-get-remote-gid): New defuns.
(tramp-local-host-p): Simplify `tramp-get-remote-uid' call.
* test/lisp/net/tramp-tests.el (tramp-test17-dired-with-wildcards)
Skip if needed.
Diffstat (limited to 'test')
| -rw-r--r-- | test/lisp/net/tramp-tests.el | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el index 9667b34c667..cb30a360225 100644 --- a/test/lisp/net/tramp-tests.el +++ b/test/lisp/net/tramp-tests.el | |||
| @@ -2998,6 +2998,8 @@ This tests also `file-directory-p' and `file-accessible-directory-p'." | |||
| 2998 | (skip-unless (tramp--test-enabled)) | 2998 | (skip-unless (tramp--test-enabled)) |
| 2999 | (skip-unless (tramp--test-sh-p)) | 2999 | (skip-unless (tramp--test-sh-p)) |
| 3000 | (skip-unless (not (tramp--test-rsync-p))) | 3000 | (skip-unless (not (tramp--test-rsync-p))) |
| 3001 | ;; Wildcards are not supported in tramp-crypt.el. | ||
| 3002 | (skip-unless (not (tramp--test-crypt-p))) | ||
| 3001 | ;; Since Emacs 26.1. | 3003 | ;; Since Emacs 26.1. |
| 3002 | (skip-unless (fboundp 'insert-directory-wildcard-in-dir-p)) | 3004 | (skip-unless (fboundp 'insert-directory-wildcard-in-dir-p)) |
| 3003 | 3005 | ||