skill: warning printout for non-existing processes

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2011-10-22 09:47:46 +02:00
parent 991b8a94f0
commit b4b73df69c

View File

@ -134,9 +134,8 @@ static void check_proc(int pid, struct run_time_conf_t *run_time)
fd = open(buf, O_RDONLY); fd = open(buf, O_RDONLY);
if (fd == -1) { if (fd == -1) {
/* process exited maybe */ /* process exited maybe */
if (pids && run_time->warnings) if (run_time->warnings)
printf(_("WARNING: process %d could not be found.\n"), warn(_("cannot open file %s"), buf);
pid);
return; return;
} }
fstat(fd, &statbuf); fstat(fd, &statbuf);