summaryrefslogtreecommitdiff
path: root/src/shell_manager.cc
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2022-01-24 21:59:16 +1100
committerMaxime Coste <mawww@kakoune.org>2022-01-24 21:59:16 +1100
commitf8a86149e5ef5f41c7d40db12ced6f02bf2def0e (patch)
tree83e0c6aa485a31e4e962b3736ce0dce8c4aaa0f3 /src/shell_manager.cc
parent6f135c0c8e4d4d5b66cd6b56394ad7d690a16252 (diff)
Use strerror to display execve failures
Fixes #4501
Diffstat (limited to 'src/shell_manager.cc')
-rw-r--r--src/shell_manager.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shell_manager.cc b/src/shell_manager.cc
index ac0eb43b..96cfb063 100644
--- a/src/shell_manager.cc
+++ b/src/shell_manager.cc
@@ -134,7 +134,7 @@ pid_t spawn_shell(const char* shell, StringView cmdline,
execve(shell, (char* const*)execparams.data(), (char* const*)envptrs.data());
char buffer[1024];
- write(STDERR_FILENO, format_to(buffer, "execve failed: {}\n", errno));
+ write(STDERR_FILENO, format_to(buffer, "execve failed: {}\n", strerror(errno)));
_exit(-1);
return -1;
}