diff options
author | Sergey Bugaev <bugaevc@gmail.com> | 2020-01-20 15:15:24 +0300 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-01-20 13:26:06 +0100 |
commit | 9bc6157998dc56cb397a352f64ba2270066f986e (patch) | |
tree | 31e264a1e5add34b81c2d39b0f23cd52c482d6fc /Kernel | |
parent | b25210ee1b04bf3a317cbca7e8ba7acaaf8ad54a (diff) | |
download | serenity-9bc6157998dc56cb397a352f64ba2270066f986e.zip |
Kernel: Return new fd from sys$fcntl(F_DUPFD)
This fixes GNU Bash getting confused after performing a redirection.
Diffstat (limited to 'Kernel')
-rw-r--r-- | Kernel/Process.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Process.cpp b/Kernel/Process.cpp index e60b719727..11a6c9845b 100644 --- a/Kernel/Process.cpp +++ b/Kernel/Process.cpp @@ -1741,7 +1741,7 @@ int Process::sys$fcntl(int fd, int cmd, u32 arg) if (new_fd < 0) return new_fd; m_fds[new_fd].set(*description); - break; + return new_fd; } case F_GETFD: return m_fds[fd].flags; |