diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2017-04-12 15:48:19 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2017-04-12 15:48:19 +0200 |
commit | d9eb40c18519d10aac3b3d008aa7e338ae830b72 (patch) | |
tree | cffe3867dedefadb361ec6cbd507e9f967e36e90 /procps | |
parent | 0cecbe7d5de237a6c699c67ae53ae2e2481eff43 (diff) | |
download | busybox-w32-d9eb40c18519d10aac3b3d008aa7e338ae830b72.tar.gz busybox-w32-d9eb40c18519d10aac3b3d008aa7e338ae830b72.tar.bz2 busybox-w32-d9eb40c18519d10aac3b3d008aa7e338ae830b72.zip |
fix errors found with make_single_applets.sh
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'procps')
-rw-r--r-- | procps/kill.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/procps/kill.c b/procps/kill.c index 7ae5beead..975a3e8c5 100644 --- a/procps/kill.c +++ b/procps/kill.c | |||
@@ -201,7 +201,7 @@ int kill_main(int argc UNUSED_PARAM, char **argv) | |||
201 | pid_t sid; | 201 | pid_t sid; |
202 | procps_status_t* p = NULL; | 202 | procps_status_t* p = NULL; |
203 | /* compat: exitcode 2 is "no one was signaled" */ | 203 | /* compat: exitcode 2 is "no one was signaled" */ |
204 | int ret = 2; | 204 | errors = 2; |
205 | 205 | ||
206 | /* Find out our session id */ | 206 | /* Find out our session id */ |
207 | sid = getsid(pid); | 207 | sid = getsid(pid); |
@@ -229,7 +229,7 @@ int kill_main(int argc UNUSED_PARAM, char **argv) | |||
229 | arg = *args++; | 229 | arg = *args++; |
230 | if (arg[0] != '-' || arg[1] != 'o') { | 230 | if (arg[0] != '-' || arg[1] != 'o') { |
231 | bb_error_msg("bad option '%s'", arg); | 231 | bb_error_msg("bad option '%s'", arg); |
232 | ret = 1; | 232 | errors = 1; |
233 | goto resume; | 233 | goto resume; |
234 | } | 234 | } |
235 | arg += 2; | 235 | arg += 2; |
@@ -238,21 +238,21 @@ int kill_main(int argc UNUSED_PARAM, char **argv) | |||
238 | omit = bb_strtoi(arg, NULL, 10); | 238 | omit = bb_strtoi(arg, NULL, 10); |
239 | if (errno) { | 239 | if (errno) { |
240 | bb_error_msg("invalid number '%s'", arg); | 240 | bb_error_msg("invalid number '%s'", arg); |
241 | ret = 1; | 241 | errors = 1; |
242 | goto resume; | 242 | goto resume; |
243 | } | 243 | } |
244 | if (p->pid == omit) | 244 | if (p->pid == omit) |
245 | goto dont_kill; | 245 | goto dont_kill; |
246 | } | 246 | } |
247 | kill(p->pid, signo); | 247 | kill(p->pid, signo); |
248 | ret = 0; | 248 | errors = 0; |
249 | dont_kill: ; | 249 | dont_kill: ; |
250 | } | 250 | } |
251 | resume: | 251 | resume: |
252 | /* And let them continue */ | 252 | /* And let them continue */ |
253 | if (signo != SIGSTOP && signo != SIGCONT) | 253 | if (signo != SIGSTOP && signo != SIGCONT) |
254 | kill(-1, SIGCONT); | 254 | kill(-1, SIGCONT); |
255 | return ret; | 255 | return errors; |
256 | } | 256 | } |
257 | 257 | ||
258 | #if ENABLE_KILL || ENABLE_KILLALL | 258 | #if ENABLE_KILL || ENABLE_KILLALL |