emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/emacs-24 r108073: Avoid two crashes involvi


From: Chong Yidong
Subject: [Emacs-diffs] /srv/bzr/emacs/emacs-24 r108073: Avoid two crashes involving windows on dead frames.
Date: Thu, 19 Jul 2012 11:33:08 +0800
User-agent: Bazaar (2.5.0)

------------------------------------------------------------
revno: 108073
fixes bug: http://debbugs.gnu.org/11984
committer: Chong Yidong <address@hidden>
branch nick: emacs-24
timestamp: Thu 2012-07-19 11:33:08 +0800
message:
  Avoid two crashes involving windows on dead frames.
  
  * window.c (Fwindow_absolute_pixel_edges)
  (Fdelete_other_windows_internal): Signal an error if the window is
  on a dead frame.
modified:
  src/ChangeLog
  src/window.c
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2012-07-14 10:46:56 +0000
+++ b/src/ChangeLog     2012-07-19 03:33:08 +0000
@@ -1,3 +1,9 @@
+2012-07-19  Chong Yidong  <address@hidden>
+
+       * window.c (Fwindow_absolute_pixel_edges)
+       (Fdelete_other_windows_internal): Signal an error if the window is
+       on a dead frame (Bug#11984).
+
 2012-07-14  Eli Zaretskii  <address@hidden>
 
        Remove FILE_SYSTEM_CASE.

=== modified file 'src/window.c'
--- a/src/window.c      2012-04-23 16:22:23 +0000
+++ b/src/window.c      2012-07-19 03:33:08 +0000
@@ -484,9 +484,7 @@
   (Lisp_Object window, Lisp_Object limit)
 {
   register struct window *w = decode_any_window (window);
-
   w->combination_limit = limit;
-
   return w->combination_limit;
 }
 
@@ -800,6 +798,8 @@
 {
   register struct window *w = decode_any_window (window);
   int add_x, add_y;
+
+  CHECK_LIVE_FRAME (w->frame);
   calc_absolute_offset (w, &add_x, &add_y);
 
   return Fcons (make_number (WINDOW_LEFT_EDGE_X (w) + add_x),
@@ -2568,6 +2568,7 @@
   Mouse_HLInfo *hlinfo;
 
   w = decode_any_window (window);
+  CHECK_LIVE_FRAME (w->frame);
   XSETWINDOW (window, w);
   f = XFRAME (w->frame);
 
@@ -2581,6 +2582,7 @@
     /* ROOT must be an ancestor of WINDOW.  */
     {
       r = decode_any_window (root);
+      CHECK_LIVE_FRAME (r->frame);
       pwindow = XWINDOW (window)->parent;
       while (!NILP (pwindow))
        if (EQ (pwindow, root))


reply via email to

[Prev in Thread] Current Thread [Next in Thread]