aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChong Yidong2008-12-11 20:38:36 +0000
committerChong Yidong2008-12-11 20:38:36 +0000
commit9f215d25e03320d6fea344f87894fcae64c9375f (patch)
tree9722362f49722f9fe8683f46cb1216d665cae147 /src
parentec4e88d751b85c1453aae7686b190e9dca25f1b7 (diff)
downloademacs-9f215d25e03320d6fea344f87894fcae64c9375f.tar.gz
emacs-9f215d25e03320d6fea344f87894fcae64c9375f.zip
(tty_free_frame_resources): Renamed from delete_tty_output; all
callers changed. Call free_frame_faces to free the face cache.
Diffstat (limited to 'src')
-rw-r--r--src/term.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/term.c b/src/term.c
index 32bc4f6eea8..fd1590547c1 100644
--- a/src/term.c
+++ b/src/term.c
@@ -3183,14 +3183,17 @@ create_tty_output (struct frame *f)
3183 f->output_data.tty = t; 3183 f->output_data.tty = t;
3184} 3184}
3185 3185
3186/* Delete the tty-dependent part of frame F. */ 3186/* Delete frame F's face cache, and its tty-dependent part. */
3187 3187
3188static void 3188static void
3189delete_tty_output (struct frame *f) 3189tty_free_frame_resources (struct frame *f)
3190{ 3190{
3191 if (! FRAME_TERMCAP_P (f)) 3191 if (! FRAME_TERMCAP_P (f))
3192 abort (); 3192 abort ();
3193 3193
3194 if (FRAME_FACE_CACHE (f))
3195 free_frame_faces (f);
3196
3194 xfree (f->output_data.tty); 3197 xfree (f->output_data.tty);
3195} 3198}
3196 3199
@@ -3229,7 +3232,7 @@ clear_tty_hooks (struct terminal *terminal)
3229 3232
3230 /* Leave these two set, or suspended frames are not deleted 3233 /* Leave these two set, or suspended frames are not deleted
3231 correctly. */ 3234 correctly. */
3232 terminal->delete_frame_hook = &delete_tty_output; 3235 terminal->delete_frame_hook = &tty_free_frame_resources;
3233 terminal->delete_terminal_hook = &delete_tty; 3236 terminal->delete_terminal_hook = &delete_tty;
3234} 3237}
3235 3238
@@ -3273,7 +3276,7 @@ set_tty_hooks (struct terminal *terminal)
3273 terminal->read_socket_hook = &tty_read_avail_input; /* keyboard.c */ 3276 terminal->read_socket_hook = &tty_read_avail_input; /* keyboard.c */
3274 terminal->frame_up_to_date_hook = 0; /* Not needed. */ 3277 terminal->frame_up_to_date_hook = 0; /* Not needed. */
3275 3278
3276 terminal->delete_frame_hook = &delete_tty_output; 3279 terminal->delete_frame_hook = &tty_free_frame_resources;
3277 terminal->delete_terminal_hook = &delete_tty; 3280 terminal->delete_terminal_hook = &delete_tty;
3278} 3281}
3279 3282
@@ -3452,7 +3455,7 @@ init_tty (char *name, char *terminal_type, int must_succeed)
3452 tty->output = stdout; 3455 tty->output = stdout;
3453 tty->input = stdin; 3456 tty->input = stdin;
3454 /* The following two are inaccessible from w32console.c. */ 3457 /* The following two are inaccessible from w32console.c. */
3455 terminal->delete_frame_hook = &delete_tty_output; 3458 terminal->delete_frame_hook = &tty_free_frame_resources;
3456 terminal->delete_terminal_hook = &delete_tty; 3459 terminal->delete_terminal_hook = &delete_tty;
3457 3460
3458 tty->name = xstrdup (name); 3461 tty->name = xstrdup (name);