[gnu.emacs.bug] deleted window bug

liberte@M.CS.UIUC.EDU (Daniel LaLiberte) (03/23/89)

In 18.52, compiled for X11, but started with -nw, two related bugs
occur when a window is deleted.  

If a variable w is set to a window object as in (setq w
(selected-window)), and then the window is deleted with
delete-window, w still points to the window object.  That would be
fine, except that the window object is not marked as being deleted,
analogous to killed buffers.  Functions like window-height, etc
still look at the window object and return info as if the window
were still alive.  

Worse things happen when the buffer associated with the window
object is killed.  Displaying the window object gives things like:
#<window 4 on ^A^OD^H^A^OD^\^A^OD^H>, although (window-buffer w)
says #<killed buffer>.  Deleting such a window results in a fatal error.

One way to test if a window w is deleted is to do (window-point w).
The result is nil if the window is deleted, whether or not the buffer
exists.  This appears to work, but I dont see in the source for
delete-window how this happens.

dan