Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Fork child process, wait 5 seconds and kill it */
- pid_t pid = fork();
- if(pid =! 0) {
- /* Parent */
- sleep(5);
- kill(pid, 11);
- }
- else {
- /* Child process. Would contain some code */
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement