summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2025-06-13 19:16:27 -0400
committerIan Moffett <ian@osmora.org>2025-06-13 19:16:27 -0400
commit68fbe4a2292dc5b4025dd4201fd4b892605079b7 (patch)
treeb2683975dc48116a57a7c7911712b63749a176b1 /usr.bin
parent9f534c75cd0e29b5b829c412ced28fa846c7d911 (diff)
kernel: spawn: Add argv + stub envp arguments
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/osh/osh.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/osh/osh.c b/usr.bin/osh/osh.c
index 93ac876..aaa4502 100644
--- a/usr.bin/osh/osh.c
+++ b/usr.bin/osh/osh.c
@@ -219,6 +219,7 @@ static int
cmd_run(const char *input, int argc, char *argv[])
{
char bin_path[256];
+ char *envp[1] = { NULL };
int error;
snprintf(bin_path, sizeof(bin_path), "/usr/bin/%s", input);
@@ -228,7 +229,7 @@ cmd_run(const char *input, int argc, char *argv[])
return -1;
}
- if ((error = spawn(bin_path, SPAWN_WAIT)) < 0) {
+ if ((error = spawn(bin_path, argv, envp, SPAWN_WAIT)) < 0) {
return error;
}