ncdirect: drop signals in ncdirect_stop_minimal

pull/1279/head
nick black 4 years ago
parent 21f6b5fc8a
commit 4427713f0f
No known key found for this signature in database
GPG Key ID: 5F43400C21CBFACC

@ -595,7 +595,7 @@ int get_controlling_tty(FILE* ttyfp){
static int
ncdirect_stop_minimal(void* vnc){
ncdirect* nc = static_cast<ncdirect*>(vnc);
int ret = 0;
int ret = drop_signals(nc);
if(nc->tcache.op && term_emit("op", nc->tcache.op, nc->ttyfp, true)){
ret = -1;
}
@ -681,6 +681,7 @@ err:
tcsetattr(ret->ctermfd, TCSANOW, &ret->tpreserved);
}
}
drop_signals(ret);
delete(ret);
return nullptr;
}

@ -58,8 +58,7 @@ reset_term_attributes(notcurses* nc){
static int
notcurses_stop_minimal(void* vnc){
notcurses* nc = vnc;
int ret = 0;
drop_signals(nc);
int ret = drop_signals(nc);
// be sure to write the restoration sequences *prior* to running rmcup, as
// they apply to the screen (alternate or otherwise) we're actually using.
ret |= reset_term_attributes(nc);

Loading…
Cancel
Save