mirror of
https://github.com/fish-shell/fish-shell
synced 2024-09-21 06:51:58 +00:00
Also free ncurses terminal state when exiting under ASAN
This commit is contained in:
parent
73983bada5
commit
91485c90ca
1 changed files with 7 additions and 0 deletions
|
@ -325,6 +325,13 @@ pub fn asan_maybe_exit(#[allow(unused)] code: i32) {
|
|||
pub fn asan_before_exit() {
|
||||
#[cfg(feature = "asan")]
|
||||
if !is_forked_child() {
|
||||
unsafe {
|
||||
// Free ncurses terminal state
|
||||
extern "C" {
|
||||
fn env_cleanup();
|
||||
}
|
||||
env_cleanup();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue