diff options
author | Boris Faure <billiob@gmail.com> | 2016-12-04 23:21:58 +0100 |
---|---|---|
committer | Boris Faure <billiob@gmail.com> | 2016-12-04 23:21:58 +0100 |
commit | 32dbc65c6dd4a43b4c3cc1ccbf412e45b8b42f8e (patch) | |
tree | da7947b2a3caa1084c541bb6ef58da24929b8d30 | |
parent | termpty: remove useless code (diff) | |
download | terminology-32dbc65c6dd4a43b4c3cc1ccbf412e45b8b42f8e.tar.gz |
env: unset COLUMNS, LINES, TERMCAP
-rw-r--r-- | src/bin/termpty.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/bin/termpty.c b/src/bin/termpty.c index 9bd7159..6b7ad98 100644 --- a/src/bin/termpty.c +++ b/src/bin/termpty.c @@ -500,10 +500,13 @@ termpty_new(const char *cmd, Eina_Bool login_shell, const char *cd, if (ioctl(ty->slavefd, TIOCSCTTY, NULL) < 0) exit(1); - close(ty->fd); close(ty->slavefd); + close(ty->fd); - /* TODO: should we reset signals here? */ + /* Unset env variables that no longer apply */ + unsetenv("TERMCAP"); + unsetenv("COLUMNS"); + unsetenv("LINES"); /* pretend to be xterm */ if (xterm_256color) |