PatchworkOS  10941b4
A non-POSIX operating system.
Loading...
Searching...
No Matches
kill.c
Go to the documentation of this file.
1#include <sys/io.h>
2#include <sys/proc.h>
3
5{
6 return swritefile(F("/proc/%llu/ctl", pid), "kill");
7}
#define F(format,...)
Allocates a formatted string on the stack.
Definition io.h:66
size_t swritefile(const char *path, const char *string)
Wrapper for writing a null-terminated string directly to a file using a path.
Definition swritefile.c:4
uint64_t kill(pid_t pid)
Helper for sending the "kill" command to a process.
Definition kill.c:4
__UINT64_TYPE__ pid_t
Process Identifier.
Definition pid_t.h:11
__UINT64_TYPE__ uint64_t
Definition stdint.h:17