* doc/emacs/custom.texi (Connection Variables): Warn about
specifying the same variable twice.
* lisp/files-x.el (connection-local-get-profiles): Normalize criteria.
method) or @code{:user} (a remote user name). The @code{nil} criteria
matches all buffers with a remote default directory.
+ Be careful when declaring different profiles with the same variable,
+and setting these profiles to criteria which could match in parallel.
+It is unspecified which variable value is used then.
+
@node Key Bindings
@section Customizing Key Bindings
@cindex key bindings
"Return the connection profiles list for CRITERIA.
CRITERIA is a plist identifying a connection and the application
using this connection, see `connection-local-criteria-alist'."
- (let (profiles)
+ (let ((criteria (connection-local-normalize-criteria criteria))
+ profiles)
(dolist (crit-alist connection-local-criteria-alist)
(let ((crit criteria)
(match t))