diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2007-04-19 17:26:34 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2007-04-19 17:26:34 +0000 |
commit | 05a6d9cbb202b8aa7379e39dfd09baccfbfc6c4b (patch) | |
tree | b520bc162f092155e277ccd1151ca370529ccdd5 /shell | |
parent | 8581863a1b536e2db20036e680b58cc07c54ad55 (diff) | |
download | busybox-w32-05a6d9cbb202b8aa7379e39dfd09baccfbfc6c4b.tar.gz busybox-w32-05a6d9cbb202b8aa7379e39dfd09baccfbfc6c4b.tar.bz2 busybox-w32-05a6d9cbb202b8aa7379e39dfd09baccfbfc6c4b.zip |
doc: add README on shell job control
Diffstat (limited to 'shell')
-rw-r--r-- | shell/README.job | 237 |
1 files changed, 237 insertions, 0 deletions
diff --git a/shell/README.job b/shell/README.job new file mode 100644 index 000000000..b29d31588 --- /dev/null +++ b/shell/README.job | |||
@@ -0,0 +1,237 @@ | |||
1 | strace of "sleep 1 | sleep 2" being run from interactive bash 3.0 | ||
2 | |||
3 | |||
4 | Synopsis: | ||
5 | get current signal mask | ||
6 | install default handlers for GHLD QUIT TERM | ||
7 | install common handler for HUP INT ILL TRAP ABRT FPE BUS SEGV SYS PIPE ALRM TERM XCPU XFSZ VTALRM USR1 USR2 | ||
8 | ignore QUIT | ||
9 | install handler for INT | ||
10 | ignore TERM | ||
11 | install handler for INT | ||
12 | ignore TSTP TTOU TTIN | ||
13 | install handler for WINCH | ||
14 | get pid, ppid | ||
15 | block all signals | ||
16 | unblock all signals | ||
17 | get our pprocess group | ||
18 | minidoc: | ||
19 | Each process group is a member of a session and each process is a member | ||
20 | of the session of which its process group is a member. | ||
21 | Process groups are used for distribution of signals, and by terminals | ||
22 | to arbitrate requests for their input: processes that have the same | ||
23 | process group as the terminal are foreground and may read, while others | ||
24 | will block with a signal if they attempt to read. These calls are thus used | ||
25 | by programs (shells) to create process groups in implementing job control. | ||
26 | The TIOCGPGRP and TIOCSPGRP calls described in termios(3) are used to get/set | ||
27 | the process group of the control terminal. | ||
28 | If a session has a controlling terminal, CLOCAL is not set and a hangup occurs, | ||
29 | then the session leader is sent a SIGHUP. If the session leader exits, | ||
30 | the SIGHUP signal will be sent to each process in the foreground process | ||
31 | group of the controlling terminal. | ||
32 | If the exit of the process causes a process group to become orphaned, | ||
33 | and if any member of the newly-orphaned process group is stopped, then a SIGHUP | ||
34 | signal followed by a SIGCONT signal will be sent to each process | ||
35 | in the newly-orphaned process group. | ||
36 | ... | ||
37 | |||
38 | |||
39 | |||
40 | execve("/bin/sh", ["sh"], [/* 34 vars */]) = 0 | ||
41 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
42 | rt_sigaction(SIGCHLD, {SIG_DFL}, {SIG_DFL}, 8) = 0 | ||
43 | rt_sigaction(SIGQUIT, {SIG_DFL}, {SIG_DFL}, 8) = 0 | ||
44 | rt_sigaction(SIGTERM, {SIG_DFL}, {SIG_DFL}, 8) = 0 | ||
45 | rt_sigaction(SIGHUP, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
46 | rt_sigaction(SIGINT, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
47 | rt_sigaction(SIGILL, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
48 | rt_sigaction(SIGTRAP, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
49 | rt_sigaction(SIGABRT, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
50 | rt_sigaction(SIGFPE, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
51 | rt_sigaction(SIGBUS, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
52 | rt_sigaction(SIGSEGV, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
53 | rt_sigaction(SIGSYS, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
54 | rt_sigaction(SIGPIPE, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
55 | rt_sigaction(SIGALRM, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
56 | rt_sigaction(SIGTERM, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
57 | rt_sigaction(SIGXCPU, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
58 | rt_sigaction(SIGXFSZ, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
59 | rt_sigaction(SIGVTALRM, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
60 | rt_sigaction(SIGUSR1, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
61 | rt_sigaction(SIGUSR2, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
62 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
63 | rt_sigaction(SIGQUIT, {SIG_IGN}, {SIG_DFL}, 8) = 0 | ||
64 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
65 | rt_sigaction(SIGTERM, {SIG_IGN}, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
66 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
67 | rt_sigaction(SIGTSTP, {SIG_IGN}, {SIG_DFL}, 8) = 0 | ||
68 | rt_sigaction(SIGTTOU, {SIG_IGN}, {SIG_DFL}, 8) = 0 | ||
69 | rt_sigaction(SIGTTIN, {SIG_IGN}, {SIG_DFL}, 8) = 0 | ||
70 | rt_sigaction(SIGWINCH, {0x807dc33, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
71 | getpid() = 19473 | ||
72 | getppid() = 19472 | ||
73 | rt_sigprocmask(SIG_BLOCK, ~[], [], 8) = 0 | ||
74 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
75 | getpgrp() = 1865 | ||
76 | dup(2) = 4 | ||
77 | fcntl64(255, F_GETFD) = -1 EBADF (Bad file descriptor) | ||
78 | dup2(4, 255) = 255 | ||
79 | close(4) = 0 | ||
80 | ioctl(255, TIOCGPGRP, [1865]) = 0 | ||
81 | getpid() = 19473 | ||
82 | setpgid(0, 19473) = 0 | ||
83 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [], 8) = 0 | ||
84 | ioctl(255, TIOCSPGRP, [19473]) = 0 | ||
85 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
86 | fcntl64(255, F_SETFD, FD_CLOEXEC) = 0 | ||
87 | rt_sigaction(SIGCHLD, {0x807c922, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_DFL}, 8) = 0 | ||
88 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
89 | fcntl64(0, F_GETFL) = 0x2 (flags O_RDWR) | ||
90 | ... | ||
91 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
92 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
93 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [], 8) = 0 | ||
94 | ioctl(255, TIOCSPGRP, [19473]) = 0 | ||
95 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
96 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
97 | rt_sigprocmask(SIG_BLOCK, ~[], [], 8) = 0 | ||
98 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
99 | rt_sigprocmask(SIG_BLOCK, [INT], [], 8) = 0 | ||
100 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
101 | rt_sigaction(SIGINT, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
102 | rt_sigaction(SIGTERM, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
103 | rt_sigaction(SIGTERM, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
104 | rt_sigaction(SIGQUIT, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
105 | rt_sigaction(SIGQUIT, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
106 | rt_sigaction(SIGALRM, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
107 | rt_sigaction(SIGTSTP, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
108 | rt_sigaction(SIGTSTP, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
109 | rt_sigaction(SIGTTOU, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
110 | rt_sigaction(SIGTTOU, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
111 | rt_sigaction(SIGTTIN, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
112 | rt_sigaction(SIGTTIN, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
113 | rt_sigaction(SIGWINCH, {0x80ca5cd, [], SA_RESTORER|SA_RESTART, 0x6ff7a4f8}, {0x807dc33, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
114 | rt_sigprocmask(SIG_BLOCK, ~[], [], 8) = 0 | ||
115 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
116 | rt_sigprocmask(SIG_BLOCK, ~[], [], 8) = 0 | ||
117 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
118 | rt_sigprocmask(SIG_BLOCK, ~[], [], 8) = 0 | ||
119 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
120 | write(2, "sh-3.00# ", 9) = 9 | ||
121 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
122 | read(0, "s", 1) = 1 | ||
123 | write(2, "s", 1) = 1 | ||
124 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
125 | read(0, "l", 1) = 1 | ||
126 | write(2, "l", 1) = 1 | ||
127 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
128 | ... rest of "sleep 1 | sleep 2" entered... | ||
129 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
130 | read(0, "2", 1) = 1 | ||
131 | write(2, "2", 1) = 1 | ||
132 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
133 | read(0, "\r", 1) = 1 | ||
134 | write(2, "\n", 1) = 1 | ||
135 | rt_sigprocmask(SIG_BLOCK, [INT], [], 8) = 0 | ||
136 | ioctl(0, SNDCTL_TMR_STOP or TCSETSW, {B38400 opost isig icanon echo ...}) = 0 | ||
137 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
138 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
139 | rt_sigaction(SIGTERM, {SIG_IGN}, {SIG_IGN}, 8) = 0 | ||
140 | rt_sigaction(SIGQUIT, {SIG_IGN}, {SIG_IGN}, 8) = 0 | ||
141 | rt_sigaction(SIGALRM, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
142 | rt_sigaction(SIGTSTP, {SIG_IGN}, {SIG_IGN}, 8) = 0 | ||
143 | rt_sigaction(SIGTTOU, {SIG_IGN}, {SIG_IGN}, 8) = 0 | ||
144 | rt_sigaction(SIGTTIN, {SIG_IGN}, {SIG_IGN}, 8) = 0 | ||
145 | rt_sigaction(SIGWINCH, {0x807dc33, [], SA_RESTORER, 0x6ff7a4f8}, {0x80ca5cd, [], SA_RESTORER|SA_RESTART, 0x6ff7a4f8}, 8) = 0 | ||
146 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
147 | rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 | ||
148 | pipe([4, 5]) = 0 | ||
149 | rt_sigprocmask(SIG_BLOCK, [INT CHLD], [CHLD], 8) = 0 | ||
150 | fork() = 19755 | ||
151 | setpgid(19755, 19755) = 0 | ||
152 | rt_sigprocmask(SIG_SETMASK, [CHLD], NULL, 8) = 0 | ||
153 | close(5) = 0 | ||
154 | rt_sigprocmask(SIG_BLOCK, [INT CHLD], [CHLD], 8) = 0 | ||
155 | fork() = 19756 | ||
156 | setpgid(19756, 19755) = 0 | ||
157 | rt_sigprocmask(SIG_SETMASK, [CHLD], NULL, 8) = 0 | ||
158 | close(4) = 0 | ||
159 | rt_sigprocmask(SIG_BLOCK, [CHLD], [CHLD], 8) = 0 | ||
160 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [CHLD], 8) = 0 | ||
161 | ioctl(255, TIOCSPGRP, [19755]) = 0 | ||
162 | rt_sigprocmask(SIG_SETMASK, [CHLD], NULL, 8) = 0 | ||
163 | rt_sigprocmask(SIG_SETMASK, [CHLD], NULL, 8) = 0 | ||
164 | rt_sigprocmask(SIG_BLOCK, [CHLD], [CHLD], 8) = 0 | ||
165 | wait4(-1, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], WUNTRACED, NULL) = 19755 | ||
166 | wait4(-1, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], WUNTRACED, NULL) = 19756 | ||
167 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [CHLD], 8) = 0 | ||
168 | ioctl(255, TIOCSPGRP, [19473]) = 0 | ||
169 | rt_sigprocmask(SIG_SETMASK, [CHLD], NULL, 8) = 0 | ||
170 | rt_sigprocmask(SIG_SETMASK, [CHLD], NULL, 8) = 0 | ||
171 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
172 | --- SIGCHLD (Child exited) @ 0 (0) --- | ||
173 | wait4(-1, 0x77fc9c54, WNOHANG|WUNTRACED, NULL) = -1 ECHILD (No child processes) | ||
174 | sigreturn() = ? (mask now []) | ||
175 | rt_sigprocmask(SIG_BLOCK, NULL, [], 8) = 0 | ||
176 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
177 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [], 8) = 0 | ||
178 | ioctl(255, TIOCSPGRP, [19473]) = 0 | ||
179 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
180 | rt_sigaction(SIGINT, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
181 | rt_sigprocmask(SIG_BLOCK, [INT], [], 8) = 0 | ||
182 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
183 | rt_sigaction(SIGINT, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
184 | rt_sigaction(SIGTERM, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
185 | rt_sigaction(SIGTERM, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
186 | rt_sigaction(SIGQUIT, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
187 | rt_sigaction(SIGQUIT, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
188 | rt_sigaction(SIGALRM, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {0x808f752, [HUP INT ILL TRAP ABRT BUS FPE USR1 SEGV USR2 PIPE ALRM TERM XCPU XFSZ VTALRM SYS], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
189 | rt_sigaction(SIGTSTP, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
190 | rt_sigaction(SIGTSTP, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
191 | rt_sigaction(SIGTTOU, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
192 | rt_sigaction(SIGTTOU, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
193 | rt_sigaction(SIGTTIN, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, {SIG_IGN}, 8) = 0 | ||
194 | rt_sigaction(SIGTTIN, {SIG_IGN}, {0x80ca530, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
195 | rt_sigaction(SIGWINCH, {0x80ca5cd, [], SA_RESTORER|SA_RESTART, 0x6ff7a4f8}, {0x807dc33, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
196 | write(2, "sh-3.00# ", 9) = 9 | ||
197 | |||
198 | |||
199 | getpid() = 19755 | ||
200 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
201 | rt_sigaction(SIGTSTP, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
202 | rt_sigaction(SIGTTIN, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
203 | rt_sigaction(SIGTTOU, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
204 | setpgid(19755, 19755) = 0 | ||
205 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [], 8) = 0 | ||
206 | ioctl(255, TIOCSPGRP, [19755]) = 0 | ||
207 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
208 | close(4) = 0 | ||
209 | dup2(5, 1) = 1 | ||
210 | close(5) = 0 | ||
211 | rt_sigaction(SIGINT, {SIG_DFL}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
212 | rt_sigaction(SIGQUIT, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
213 | rt_sigaction(SIGTERM, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
214 | rt_sigaction(SIGCHLD, {SIG_DFL}, {0x807c922, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
215 | execve("/bin/sleep", ["sleep", "1"], [/* 34 vars */]) = 0 | ||
216 | ... | ||
217 | _exit(0) = ? | ||
218 | |||
219 | |||
220 | getpid() = 19756 | ||
221 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
222 | rt_sigaction(SIGTSTP, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
223 | rt_sigaction(SIGTTIN, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
224 | rt_sigaction(SIGTTOU, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
225 | setpgid(19756, 19755) = 0 | ||
226 | rt_sigprocmask(SIG_BLOCK, [CHLD TSTP TTIN TTOU], [], 8) = 0 | ||
227 | ioctl(255, TIOCSPGRP, [19755]) = 0 | ||
228 | rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 | ||
229 | dup2(4, 0) = 0 | ||
230 | close(4) = 0 | ||
231 | rt_sigaction(SIGINT, {SIG_DFL}, {0x808f7d7, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
232 | rt_sigaction(SIGQUIT, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
233 | rt_sigaction(SIGTERM, {SIG_DFL}, {SIG_IGN}, 8) = 0 | ||
234 | rt_sigaction(SIGCHLD, {SIG_DFL}, {0x807c922, [], SA_RESTORER, 0x6ff7a4f8}, 8) = 0 | ||
235 | execve("/bin/sleep", ["sleep", "2"], [/* 34 vars */]) = 0 | ||
236 | ... | ||
237 | _exit(0) = ? | ||