diff options
| author | Kacper <kacper@mail.openlinux.dev> | 2025-12-09 21:17:12 +0100 |
|---|---|---|
| committer | Kacper <kacper@mail.openlinux.dev> | 2025-12-09 21:17:12 +0100 |
| commit | b5cd18739a64c8d923a55b61c89ae3900faafd84 (patch) | |
| tree | d192f7b25257ae9a8a4760c68f5314dcbc0d9b91 /lib/libc/stdio/popen.c | |
| parent | 119aed5bc787ccbf23d2f151759ec1f3a80977e1 (diff) | |
Fix include paths and formatting inconsistencies
Diffstat (limited to 'lib/libc/stdio/popen.c')
| -rw-r--r-- | lib/libc/stdio/popen.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/lib/libc/stdio/popen.c b/lib/libc/stdio/popen.c index 92b6a099..09c931ad 100644 --- a/lib/libc/stdio/popen.c +++ b/lib/libc/stdio/popen.c @@ -1,8 +1,10 @@ -#include <io.h> -#include <errno.h> -#include <stdio.h> -#include <fcntl.h> -#include <unistd.h> +#include "stddef.h" // for NULL + +#include <errno.h> // for EINVAL, errno +#include <fcntl.h> // for O_RDONLY, O_CLOEXEC, O_WRONLY +#include <libc.h> // for __IMPL +#include <stdio.h> // for FILE, fclose, fdopen, popen +#include <unistd.h> // for close, dup2, _exit, execl, fork, pipe2, STDIN_FI... FILE *popen(const char *command, const char *mode) { @@ -58,7 +60,7 @@ FILE *popen(const char *command, const char *mode) close(pipefd[0]); } - stream->pid = pid; + __IMPL(stream)->pid = pid; return stream; } |
