• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10.1/emacs-93/emacs/lisp/

Lines Matching +defs:start +defs:process

1 ;;; server.el --- Lisp code for GNU Emacs running as server process
82 "Emacs running as a server process."
88 (unless (featurep 'make-network-process '(:family local))
99 "The name or IP address to use as host address of the server process.
136 (defvar server-process nil
137 "The current server process.")
142 that can be given to the server process to identify a client.
228 ;; If this is a new client process, set the query-on-exit flag to nil
229 ;; for this process (it isn't inherited from the server process).
230 (when (and (eq (process-status proc) 'open)
231 (process-query-on-exit-flag proc))
232 (set-process-query-on-exit-flag proc nil))
236 ;; (and (process-contact proc :server)
237 ;; (eq (process-status proc) 'closed)
238 ;; (ignore-errors (delete-file (process-get proc :server-file))))
239 (server-log (format "Status changed to %s" (process-status proc)) proc))
307 (defun server-start (&optional leave-dead)
308 "Allow this Emacs process to be a server for client processes.
317 (when server-process
319 (ignore-errors (delete-process server-process)))
332 (when server-process
335 (setq server-process
336 (apply #'make-network-process
341 :filter 'server-process-filter
343 ;; Those are decoded by server-process-filter according
355 (unless server-process (error "Could not start server process"))
364 (process-put server-process :auth-key auth-key)
369 (process-contact server-process :local))
377 Server mode runs a process that accepts commands from the
378 `emacsclient' program. See `server-start' and Info node `Emacs server'."
384 (server-start (not server-mode)))
387 (defun* server-process-filter (proc string)
389 PROC is the server process. Format of STRING is \"PATH PATH PATH... \\n\"."
391 (unless (process-get proc :authenticated)
393 (equal (match-string 1 string) (process-get proc :auth-key)))
396 (process-put proc :authenticated t)
399 (process-send-string proc "Authentication failed")
400 (delete-process proc)
402 (return-from server-process-filter)))
404 (let ((prev (process-get proc :previous-string)))
407 (process-put proc :previous-string nil)))
414 (process-put proc :previous-string string)
416 (lambda () (server-process-filter proc ""))))
429 ;; process each line individually.
454 (error (process-send-string proc (nth 1 err))
481 (process-send-region proc (point-min) (point-max)))
497 (delete-process proc)
513 (process-put proc :previous-string string)))
590 (delete-process (car client))
687 (when server-process
703 If invoked with a prefix argument, or if there is no server process running,
704 starts server process and that is all. Invoked by \\[server-edit]."
708 (not server-process)
709 (memq (process-status server-process) '(signal exit)))