diff options
author | Christian Göttsche <cgzones@googlemail.com> | 2022-08-14 19:56:49 +0200 |
---|---|---|
committer | BenBE <BenBE@geshi.org> | 2022-08-22 21:32:49 +0200 |
commit | 5aa207f9af6622583fd60edebaef1c3ed19ab91d (patch) | |
tree | 77efbebc0b6fe15d70911c99a9082b6e70bff867 | |
parent | 584124c9f4032046b4ed4a3f16ec5ee97ab08c4b (diff) |
Display failures from initscr
initscr(3) might fail, e.g. if the environment variable TERM is not set,
and directly exit the program. Thus redirect stderr afterwards to not
hide those potential fatal failure messages:
Error opening terminal: unknown.
-rw-r--r-- | CRT.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -915,9 +915,8 @@ void CRT_setMouse(bool enabled) { #endif void CRT_init(const Settings* settings, bool allowUnicode) { - redirectStderr(); - initscr(); + redirectStderr(); noecho(); CRT_crashSettings = settings; CRT_delay = &(settings->delay); |