Merge from origin/emacs-27

2af6b3147d Clarification in Tramp manual
8fbaca7d41 Check Emacs version used for Tramp compilation
90e5549f02 Don't signal an error when saving files on WdebDAV volumes
6f73cc3579 ; * lisp/net/eww.el (eww-search-words): Doc fix.
ce0842a165 * lisp/hi-lock.el (hi-lock-find-patterns): Autoload it.  (...
This commit is contained in:
Glenn Morris 2020-10-02 09:33:53 -07:00
commit 0a769f4832
5 changed files with 35 additions and 9 deletions

View file

@ -384,7 +384,7 @@ After one of the above commands, @file{~/emacs/tramp} will
containing the latest version of @value{tramp}.
@noindent
To fetch updates from the repository, use git pull:
To fetch updates from the repository, use @code{git pull}:
@example
@group
@ -1709,9 +1709,9 @@ Integration for LXD containers. A container is accessed via
@item magit-tramp
@cindex method @option{git}
@cindex @option{git} method
Browsing git repositories with @code{magit}. A versioned file is
Browsing Git repositories with @code{magit}. A versioned file is
accessed via @file{@trampfn{git,rev@@root-dir,/path/to/file}}.
@samp{rev} is a git revision, and @samp{root-dir} is a virtual host
@samp{rev} is a Git revision, and @samp{root-dir} is a virtual host
name for the root directory, specified in
@code{magit-tramp-hosts-alist}.
@ -4866,6 +4866,18 @@ path, or somewhere else entirely (including locally). @pxref{Renaming
remote files}.
@item
I get a warning @samp{Tramp has been compiled with Emacs a.b, this is Emacs c.d}
@value{tramp} comes with compatibility code for different Emacs
versions. When you see this warning, you don't use the Emacs built-in
version of @value{tramp}. In case you have installed @value{tramp}
from GNU ELPA, you must delete and reinstall it.
@ifset installchapter
In case you have installed it from its Git repository, @ref{Recompilation}.
@end ifset
@item
How to disable other packages from calling @value{tramp}?

View file

@ -820,6 +820,7 @@ SPACES-REGEXP is a regexp to substitute spaces in font-lock search."
(font-lock-add-keywords nil hi-lock-file-patterns t)
(font-lock-flush)))
;;;###autoload
(defun hi-lock-find-patterns ()
"Add patterns from the current buffer to the list of hi-lock patterns."
(interactive)

View file

@ -450,11 +450,11 @@ killed after rendering."
;;;###autoload
(defun eww-search-words ()
"Search the web for the text between BEG and END.
"Search the web for the text in the region.
If region is active (and not whitespace), search the web for
the text between BEG and END. Else, prompt the user for a search
string. See the `eww-search-prefix' variable for the search
engine used."
the text between region beginning and end. Else, prompt the
user for a search string. See the variable `eww-search-prefix'
for the search engine used."
(interactive)
(if (use-region-p)
(let ((region-string (buffer-substring (region-beginning) (region-end))))

View file

@ -45,6 +45,14 @@
(declare-function tramp-handle-temporary-file-directory "tramp")
(defvar tramp-temp-name-prefix)
(defconst tramp-compat-emacs-compiled-version (eval-when-compile emacs-version)
"The Emacs version used for compilation.")
(unless (= emacs-major-version
(car (version-to-list tramp-compat-emacs-compiled-version)))
(warn "Tramp has been compiled with Emacs %s, this is Emacs %s"
tramp-compat-emacs-compiled-version emacs-version))
;; For not existing functions, obsolete functions, or functions with a
;; changed argument list, there are compiler warnings. We want to
;; avoid them in cases we know what we do.

View file

@ -6520,7 +6520,8 @@ acl_get_file (const char *fname, acl_type_t type)
{
xfree (psd);
err = GetLastError ();
if (err == ERROR_NOT_SUPPORTED)
if (err == ERROR_NOT_SUPPORTED
|| err == ERROR_ACCESS_DENIED)
errno = ENOTSUP;
else if (err == ERROR_FILE_NOT_FOUND
|| err == ERROR_PATH_NOT_FOUND
@ -6538,7 +6539,11 @@ acl_get_file (const char *fname, acl_type_t type)
be encoded in the current ANSI codepage. */
|| err == ERROR_INVALID_NAME)
errno = ENOENT;
else if (err == ERROR_NOT_SUPPORTED)
else if (err == ERROR_NOT_SUPPORTED
/* ERROR_ACCESS_DENIED is what we get for a volume
mounted by WebDAV, which evidently doesn't
support ACLs. */
|| err == ERROR_ACCESS_DENIED)
errno = ENOTSUP;
else
errno = EIO;