1234567891011121314151617181920212223242526 |
- #include "wait.h"
- #include <libsystem/syscall.h>
- pid_t wait(int *stat_loc)
- {
- return waitpid((pid_t)(-1), stat_loc, 0);
- }
- pid_t waitpid(pid_t pid, int *stat_loc, int options)
- {
- return (pid_t)syscall_invoke(SYS_WAIT4, (uint64_t)pid, (uint64_t)stat_loc, options, 0, 0, 0, 0, 0);
- }
|