some windows cleanup at end of game
This commit is contained in:
@@ -870,7 +870,8 @@ back_buffer_flip(void)
|
||||
do_anything |= do_wide_content;
|
||||
} else {
|
||||
#endif
|
||||
if (strcmp((const char *) back->utf8str,
|
||||
if (back->utf8str && front->utf8str
|
||||
&& strcmp((const char *) back->utf8str,
|
||||
(const char *) front->utf8str))
|
||||
do_anything |= do_utf8_content;
|
||||
#ifdef UTF8_FROM_CORE
|
||||
@@ -1184,6 +1185,7 @@ consoletty_open(int mode UNUSED)
|
||||
really_move_cursor();
|
||||
nhUse(debugvar);
|
||||
}
|
||||
extern void set_emergency_io(void);
|
||||
|
||||
void
|
||||
consoletty_exit(void)
|
||||
@@ -1191,8 +1193,10 @@ consoletty_exit(void)
|
||||
free_custom_colors();
|
||||
free((genericptr_t) console.front_buffer);
|
||||
free((genericptr_t) console.back_buffer);
|
||||
console.front_buffer = console.back_buffer = 0;
|
||||
free((genericptr_t) console.localestr);
|
||||
free((genericptr_t) console.orig_localestr);
|
||||
set_emergency_io();
|
||||
}
|
||||
|
||||
int
|
||||
|
||||
@@ -101,7 +101,7 @@ void update_file(const char *, const char *,
|
||||
const char *, const char *, BOOL);
|
||||
void windows_raw_print_bold(const char *);
|
||||
|
||||
staticfn void set_emergency_io(void);
|
||||
void set_emergency_io(void);
|
||||
staticfn void stdio_wait_synch(void);
|
||||
staticfn void stdio_raw_print(const char *str);
|
||||
staticfn void stdio_nonl_raw_print(const char *str);
|
||||
|
||||
Reference in New Issue
Block a user