mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 21:07:34 +00:00
Add tcsetpgrp()+tcgetpgrp().
One more step on the path to being able to ^C a runaway process. :^)
This commit is contained in:
parent
d8f0dd6f3b
commit
621217ffeb
11 changed files with 72 additions and 4 deletions
|
@ -25,9 +25,14 @@ pid_t setsid()
|
|||
return Syscall::invoke(Syscall::PosixSetsid);
|
||||
}
|
||||
|
||||
pid_t sys$getsid(pid_t pid)
|
||||
pid_t tcgetpgrp(int fd)
|
||||
{
|
||||
return Syscall::invoke(Syscall::PosixSetsid, (dword)pid);
|
||||
return Syscall::invoke(Syscall::PosixTcgetpgrp, (dword)fd);
|
||||
}
|
||||
|
||||
int tcsetpgrp(int fd, pid_t pgid)
|
||||
{
|
||||
return Syscall::invoke(Syscall::PosixTcsetpgrp, (dword)fd, (dword)pgid);
|
||||
}
|
||||
|
||||
int setpgid(pid_t pid, pid_t pgid)
|
||||
|
|
|
@ -16,6 +16,8 @@ pid_t getpgrp();
|
|||
uid_t getuid();
|
||||
gid_t getgid();
|
||||
pid_t getpid();
|
||||
pid_t tcgetpgrp(int fd);
|
||||
int tcsetpgrp(int fd, pid_t pgid);
|
||||
int open(const char* path, int options);
|
||||
ssize_t read(int fd, void* buf, size_t count);
|
||||
ssize_t write(int fd, const void* buf, size_t count);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue