From: Peter Oliver Date: Tue, 26 Oct 2010 07:40:07 +0000 (-0700) Subject: Add server-port option. (Bug#854) X-Git-Tag: emacs-pretest-24.0.90~104^2~275^2~438^2~45^2~455 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c79b0b1c8ccfd0c134fd8ab138353d7843fc3be8;p=emacs.git Add server-port option. (Bug#854) * lisp/server.el (server-port): New option. (server-start): Use server-port. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1293e4c8f9e..ef604bd4fef 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2010-10-26 Peter Oliver (tiny change) + + * server.el (server-port): New option. + (server-start): Use server-port. + 2010-10-26 Glenn Morris * term/ns-win.el (ns-version-string): Remove unused declaration. diff --git a/lisp/server.el b/lisp/server.el index bc49087f464..463b01ccf09 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -112,6 +112,15 @@ If set, the server accepts remote connections; otherwise it is local." :version "22.1") (put 'server-host 'risky-local-variable t) +(defcustom server-port nil + "The port number that the server process should listen on." + :group 'server + :risky t + :type '(choice + (string :tag "Port number") + (const :tag "Random" nil)) + :version "24.1") + (defcustom server-auth-dir (locate-user-emacs-file "server/") "Directory for server authentication files. @@ -564,7 +573,7 @@ server or call `M-x server-force-delete' to forcibly disconnect it.") ;; The other args depend on the kind of socket used. (if server-use-tcp (list :family 'ipv4 ;; We're not ready for IPv6 yet - :service t + :service (or server-port t) :host (or server-host 'local) :plist '(:authenticated nil)) (list :family 'local