Function: get-buffer-process
get-buffer-process is a function defined in process.c.
Signature
(get-buffer-process BUFFER)
Documentation
Return the (or a) live process associated with BUFFER.
BUFFER may be a buffer or the name of one. Return nil if all processes associated with BUFFER have been deleted or killed.
Other relevant functions are documented in the process group.
Shortdoc
;; process
(get-buffer-process buffer)
e.g. => #<process foo>
Source Code
// Defined in /usr/src/emacs/src/process.c
{
#ifdef subprocesses
register Lisp_Object buf, tail, proc;
if (NILP (buffer)) return Qnil;
buf = Fget_buffer (buffer);
if (NILP (buf)) return Qnil;
FOR_EACH_PROCESS (tail, proc)
if (EQ (XPROCESS (proc)->buffer, buf))
return proc;
#endif /* subprocesses */
return Qnil;
}