diff options
author | Andreas Kling <awesomekling@gmail.com> | 2019-02-26 22:40:35 +0100 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-02-26 22:40:35 +0100 |
commit | 424368034b21dbd363e1e8662069bb4dd2de6f4b (patch) | |
tree | c929ab21b38853e09106774cd913ed4dffd1f585 /Applications | |
parent | 83e78648e4aa989ce41f6781dafa542d518fe338 (diff) | |
download | serenity-424368034b21dbd363e1e8662069bb4dd2de6f4b.zip |
LibC: Make errno codes be #defines instead of enum values.
It turns out that a lot of 3rd party software does things like:
#ifdef EINTR
...
#endif
This won't work if EINTR is an enum. So much for that nice idea.
Diffstat (limited to 'Applications')
-rw-r--r-- | Applications/Terminal/main.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Applications/Terminal/main.cpp b/Applications/Terminal/main.cpp index 94ec08829c..5d77272c1e 100644 --- a/Applications/Terminal/main.cpp +++ b/Applications/Terminal/main.cpp @@ -64,7 +64,9 @@ static void make_shell(int ptm_fd) perror("ioctl(TIOCSCTTY)"); exit(1); } - rc = execvp("/bin/sh", nullptr); + char* args[] = { "/bin/sh", nullptr }; + char* envs[] = { "TERM=vt100", nullptr }; + rc = execve("/bin/sh", args, envs); if (rc < 0) { perror("execve"); exit(1); |