changeset 76791:6ef15c3befe4

(Fset_buffer_major_mode): Check that BUFFER is valid.
author Juanma Barranquero <lekktu@gmail.com>
date Thu, 29 Mar 2007 15:58:34 +0000
parents b7f5870e3ec1
children 7fb91844cd2e
files src/buffer.c
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/buffer.c	Thu Mar 29 13:58:40 2007 +0000
+++ b/src/buffer.c	Thu Mar 29 15:58:34 2007 +0000
@@ -1614,6 +1614,8 @@
   int count;
   Lisp_Object function;
 
+  CHECK_BUFFER (buffer);
+
   if (STRINGP (XBUFFER (buffer)->name)
       && strcmp (SDATA (XBUFFER (buffer)->name), "*scratch*") == 0)
     function = find_symbol_value (intern ("initial-major-mode"));