mirror of
https://github.com/palera1n/palera1n.git
synced 2026-10-21 09:47:01 +02:00
fix(tui): set terminfo if not already
This commit is contained in:
1 parent
3dda56f777
commit
4757655d16
1 file changed
+7
@@ -364,6 +364,13 @@ int main(int argc, char* argv[], char* envp[]) {
|
||||
|
||||
#ifdef WITH_TUI
|
||||
if (palerain_flags & palerain_option_tui) {
|
||||
// if terminfo is not set, set one
|
||||
if (getenv("TERMINFO") == nullptr) {
|
||||
// (at least on my environment) the terminal would fail to run
|
||||
// with sudo unless this is set, so if its not set correctly
|
||||
// just use a standard path on lunix
|
||||
setenv("TERMINFO", "/usr/share/terminfo", 1);
|
||||
}
|
||||
ui_run();
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user