From 8801a864d2f7d9b6a77dfffa606f27f338127582 Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Thu, 30 Mar 2000 09:56:31 +0000 Subject: * lisp.h (XCONS, XSTRING, XSYMBOL, XFLOAT, XPROCESS, XWINDOW, XSUBR, XBUFFER): Verify correct object type before returning pointer, using eassert. * frame.h (XFRAME): Likewise. * buffer.c (Frename_buffer, Fset_buffer_multibyte, swap_out_buffer_local_variables, Fmove_overlay): Don't apply XSYMBOL, XBUFFER, etc, to values that may be nil or of the wrong type. * data.c (set_internal): Likewise. * dispextern.h (WINDOW_WANTS_MODELINE_P, WINDOW_WANTS_HEADER_LINE_P): Likewise. * fileio.c (auto_save_1): Likewise. * insdel.c (check_markers): Likewise. * marker.c (buf_charpos_to_bytepos, unchain_marker): Likewise. * undo.c (record_insert): Likewise. * vmsproc.c (child_sig): Likewise. * window.c (unshow_buffer, window_loop): Likewise. * xterm.c (x_erase_phys_cursor): Likewise. --- src/data.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/data.c') diff --git a/src/data.c b/src/data.c index f736f7f6c81..c267c5540f0 100644 --- a/src/data.c +++ b/src/data.c @@ -1012,7 +1012,8 @@ set_internal (symbol, newval, buf, bindflag) isn't the right one, or if it's a Lisp_Buffer_Local_Value and the default binding is loaded, the loaded binding may be the wrong one. */ - if (buf != XBUFFER (XBUFFER_LOCAL_VALUE (valcontents)->buffer) + if (!BUFFERP (XBUFFER_LOCAL_VALUE (valcontents)->buffer) + || buf != XBUFFER (XBUFFER_LOCAL_VALUE (valcontents)->buffer) || (XBUFFER_LOCAL_VALUE (valcontents)->check_frame && !EQ (selected_frame, XBUFFER_LOCAL_VALUE (valcontents)->frame)) || (BUFFER_LOCAL_VALUEP (valcontents) -- cgit v1.2.1