aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJim Blandy1992-10-03 07:15:35 +0000
committerJim Blandy1992-10-03 07:15:35 +0000
commitff06df24f66c15bf1649072427414f8f190226ec (patch)
tree16f12f9b15d37f296f716a84940c013f9deeeda6 /src
parentbdc727bf41bcee3312d92c921d89ca31d2d6060c (diff)
downloademacs-ff06df24f66c15bf1649072427414f8f190226ec.tar.gz
emacs-ff06df24f66c15bf1649072427414f8f190226ec.zip
* window.c (SAVE_WINDOW_DATA_SIZE): Define this using sizeof,
instead of just saying it's 7; that way, we won't get screwed if we add members to struct save_window_data. * window.c (Fset_window_configuration): The pointer to the saved window data is called `data', not just `d'.
Diffstat (limited to 'src')
-rw-r--r--src/window.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/window.c b/src/window.c
index 71881ee4d49..958927d79c4 100644
--- a/src/window.c
+++ b/src/window.c
@@ -2305,7 +2305,14 @@ struct save_window_data
2305 /* A vector, interpreted as a struct saved_window */ 2305 /* A vector, interpreted as a struct saved_window */
2306 Lisp_Object saved_windows; 2306 Lisp_Object saved_windows;
2307 }; 2307 };
2308#define SAVE_WINDOW_DATA_SIZE 7 /* Arg to Fmake_vector */ 2308
2309/* Arg to Fmake_vector */
2310#define SAVE_WINDOW_DATA_SIZE \
2311 ((sizeof (struct save_window_data) \
2312 - (sizeof (struct Lisp_Vector) \
2313 /* Don't count the contents member of the struct Lisp_Vector */ \
2314 - sizeof (Lisp_Object))) \
2315 / sizeof (Lisp_Object))
2309 2316
2310/* This is saved as a Lisp_Vector */ 2317/* This is saved as a Lisp_Vector */
2311struct saved_window 2318struct saved_window
@@ -2494,7 +2501,7 @@ by `current-window-configuration' (which see).")
2494 selected window too, but that doesn't make the call to 2501 selected window too, but that doesn't make the call to
2495 Fselect_window above totally superfluous; it still sets f's 2502 Fselect_window above totally superfluous; it still sets f's
2496 selected window. */ 2503 selected window. */
2497 Fselect_frame (d->selected_frame); 2504 Fselect_frame (data->selected_frame);
2498 2505
2499 if (!NILP (new_current_buffer)) 2506 if (!NILP (new_current_buffer))
2500 Fset_buffer (new_current_buffer); 2507 Fset_buffer (new_current_buffer);