☰
Debian Codegraph
@
0.0~git20260129.ec0effd-3
0.0~git20260129.ec0effd-2
/
/
libc-top-half
/
musl
/
src
/
stdio
/
pclose.c
☽
☼
libc-top-half/musl/src/stdio/pclose.c
code
plain
raw
MIT
2005-2019 Rich Felker <
[email protected]
>; 2005-2019 Many other contributors
debian/copyright
1
#include "stdio_impl.h"
2
#include <errno.h>
3
#include <unistd.h>
4
5
int pclose(FILE *f)
6
{
7
int status, r;
8
pid_t pid = f->pipe_pid;
9
fclose(f);
10
while ((r=__sys_wait4(pid, &status, 0, 0)) == -EINTR);
11
if (r<0) return __syscall_ret(r);
12
return status;
13
}