aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman <[email protected]>1994-10-22 03:54:14 +0000
committerRichard M. Stallman <[email protected]>1994-10-22 03:54:14 +0000
commit50cf83f80f2bd17f263118efb74ee594ba9ad948 (patch)
treee30735f738fd6a08fe17798cc2f0b3ab6a3cf87c
parentf1847de368bd4c9ec757371679ae1ac65d7e5e93 (diff)
(Fframe_or_buffer_changed_p):
Detect deletion of a buffer at the end of the buffer list.
-rw-r--r--src/dispnew.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/dispnew.c b/src/dispnew.c
index eb20a71a28..787092411a 100644
--- a/src/dispnew.c
+++ b/src/dispnew.c
@@ -1886,6 +1886,10 @@ the current state.\n")
FOR_EACH_FRAME (tail, frame)
if (!EQ (*vecp++, frame))
goto changed;
+ /* Check that the buffer info matches.
+ No need to test for the end of the vector
+ because the last element of the vector is lambda
+ and that will always cause a mismatch. */
for (tail = Vbuffer_alist; CONSP (tail); tail = XCONS (tail)->cdr)
{
buf = XCONS (XCONS (tail)->car)->cdr;
@@ -1896,8 +1900,11 @@ the current state.\n")
if (!EQ (*vecp++, Fbuffer_modified_p (buf)))
goto changed;
}
- return Qnil;
+ /* Detect deletion of a buffer at the end of the list. */
+ if (*vecp == Qlambda)
+ return Qnil;
changed:
+ /* Start with 1 so there is room for at least on lambda at the end. */
n = 1;
FOR_EACH_FRAME (tail, frame)
n++;