mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-26 15:21:51 -08:00
* src/process.c (get_process): Explicit error for dead buffers
That seems more in keeping with the existing behavior of this function in other situations.
This commit is contained in:
parent
e1b01c7fed
commit
50dca5dfd6
2 changed files with 11 additions and 5 deletions
|
|
@ -1,3 +1,7 @@
|
|||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* process.c (get_process): Explicit error for dead buffers.
|
||||
|
||||
2013-11-23 Andreas Schwab <schwab@linux-m68k.org>
|
||||
|
||||
* process.c (get_process): Check that OBJ is a live buffer. (Bug#15923)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/* Asynchronous subprocess control for GNU Emacs.
|
||||
|
||||
Copyright (C) 1985-1988, 1993-1996, 1998-1999, 2001-2013 Free Software
|
||||
Foundation, Inc.
|
||||
Copyright (C) 1985-1988, 1993-1996, 1998-1999, 2001-2013
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GNU Emacs.
|
||||
|
||||
|
|
@ -812,12 +812,14 @@ get_process (register Lisp_Object name)
|
|||
else
|
||||
obj = name;
|
||||
|
||||
/* Now obj should be either a (live) buffer object or a process object. */
|
||||
if (BUFFERP (obj) && !NILP (BVAR (XBUFFER (obj), name)))
|
||||
/* Now obj should be either a buffer object or a process object. */
|
||||
if (BUFFERP (obj))
|
||||
{
|
||||
if (NILP (BVAR (XBUFFER (obj), name)))
|
||||
error ("Attempt to get process for a dead buffer");
|
||||
proc = Fget_buffer_process (obj);
|
||||
if (NILP (proc))
|
||||
error ("Buffer %s has no process", SDATA (BVAR (XBUFFER (obj), name)));
|
||||
error ("Buffer %s has no process", SDATA (BVAR (XBUFFER (obj), name)));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue