Code:
.
.
.
[532] read(0, 0x400059b0, 1024) .......................... [sleeping]
wc p
[532] read(0, "w c p \n", 1024) ........................ = 5
.
.
.
[532] fork() ............................................. = 536
[536] fork() .......... (returning as child ...) ......... = 532
.
.
.
[536] execve(0x40056b32, 0x400564ac, 0x4005677c) ......... [entry]
argv[0] @ 0x4005647d: "wc"
argv[1] @ 0x4005649d: "p"
[536] execve("/usr/bin/wc", 0x400564ac, 0x4005677c) ...... = 0 [32-bit]
.
.
.
[536] open(0x7b0f0003, O_RDONLY|O_LARGEFILE, 0666) ....... [sleeping]
(^Z)
[532] waitpid(-1, WIFSTOPPED(SIGTSTP), WUNTRACED) ........ = 536
[532] sigvec(SIGCLD, 0x7b118258, 0x7b118268) ............. = 0
[532] waitpid(-1, WIFSTOPPED(SIGTSTP), WNOHANG|WUNTRACED) = 0
[532] sigvec(SIGCLD, 0x7b118258, 0x7b118268) ............. = 0
[532] sigvec(SIGCLD, 0x7b118198, 0x7b1181a8) ............. = 0
[532] ioctl(2, TIOCGPGRP, 0x7b1181d0) .................... = 0
[532] ioctl(2, TIOCSPGRP, 0x7b118198) .................... = 0
[532] ioctl(2, TCSETATTRF, 0x40004e80) ................... = 0
[532] sigprocmask(SIG_BLOCK, 0x7b1180f0, 0x7b1180d0) ..... = 0
[532] sigprocmask(SIG_SETMASK, 0x7b1180d0, NULL) ......... = 0
[532] sigvec(SIGCLD, 0x7b117d98, 0x7b117da8) ............. = 0
[532] waitpid(-1, WIFSTOPPED(SIGTSTP), WNOHANG|WUNTRACED) = 0
[532] sigvec(SIGCLD, 0x7b117d98, 0x7b117da8) ............. = 0
[532] lseek(2047, 864312, SEEK_SET) ...................... = 864312
[532] sigprocmask(SIG_BLOCK, 0x7b117f30, 0x7b117f10) ..... = 0
[532] read(2047, "w c p \n\0", 1024) ................... = 6
[532] sigprocmask(SIG_SETMASK, 0x7b117f10, NULL) ......... = 0
[532] time(0x7b117c50) ................................... = 1287760639
[532] lseek(2047, 864318, SEEK_SET) ...................... = 864318
[532] sigprocmask(SIG_BLOCK, 0x7b117db0, 0x7b117d90) ..... = 0
[532] read(2047, 0x40055c98, 1024) ....................... = 0
[532] sigprocmask(SIG_SETMASK, 0x7b117d90, NULL) ......... = 0
[532] ioctl(0, TIOCGWINSZ, 0x7b117d10) ................... = 0
[1] + Stopped wc p
$ [532] write(2, "[ 1 ] + S t o p p e d ".., 38) . = 38
[532] sigvec(SIGCLD, 0x7b117ed8, 0x7b117ee8) ............. = 0
[532] waitpid(-1, WIFSTOPPED(SIGTSTP), WNOHANG|WUNTRACED) = 0
[532] sigvec(SIGCLD, 0x7b117ed8, 0x7b117ee8) ............. = 0
[532] sigprocmask(SIG_BLOCK, 0x7b117db0, 0x7b117d90) ..... = 0
[532] read(0, 0x400059b0, 1024) .......................... [sleeping]