mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-25 15:26:17 +02:00
Handle SIGWINCH in main thread
For the SIGWINCH signal to be caught, it needs to be set in sigaction on the main thread. Previously, this was broken, and updateWindowSize was never being called. Tested on macOS 10.14.
This commit is contained in:
parent
fb0ad898ed
commit
4a3e96281d
1 changed files with 3 additions and 0 deletions
|
@ -125,6 +125,9 @@ void initNix()
|
||||||
act.sa_handler = sigHandler;
|
act.sa_handler = sigHandler;
|
||||||
if (sigaction(SIGUSR1, &act, 0)) throw SysError("handling SIGUSR1");
|
if (sigaction(SIGUSR1, &act, 0)) throw SysError("handling SIGUSR1");
|
||||||
|
|
||||||
|
/* Make sure SIGWINCH is handled as well. */
|
||||||
|
if (sigaction(SIGWINCH, &act, 0)) throw SysError("handling SIGWINCH");
|
||||||
|
|
||||||
/* Register a SIGSEGV handler to detect stack overflows. */
|
/* Register a SIGSEGV handler to detect stack overflows. */
|
||||||
detectStackOverflow();
|
detectStackOverflow();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue