@file{server} in a well-known directory, typically
@file{$XDG_RUNTIME_DIR/emacs} if Emacs is running under an X Window System
desktop and @file{$TMPDIR/emacs@var{userid}} otherwise. See the variable
-@code{server-socket-dir}.
+@code{server-socket-dir}. Traditionally, Emacs used
+@file{$TMPDIR/emacs@var{userid}} even when running under an X desktop;
+if you prefer this traditional (and less-secure) behavior, unset
+@env{XDG_RUNTIME_DIR} before invoking Emacs and @samp{emacsclient}.
To get your news reader, mail reader, etc., to invoke
@samp{emacsclient}, try setting the environment variable @code{EDITOR}
as the directory for client/server sockets, if Emacs is running
under an X Window System desktop that sets the XDG_RUNTIME_DIR
environment variable to indicate where session sockets should go.
+To get the old and less-secure behavior, unset XDG_RUNTIME_DIR before
+invoking emacs and emacsclient.
---
*** When run by root, emacsclient no longer connects to non-root sockets.