Commit cf77cfac authored by Pavel Tikhomirov's avatar Pavel Tikhomirov Committed by Andrei Vagin

log: add line breaks to pr_warn

for i in $(find . -name "*.[ch]" -type f); do
	sed -i 's/\(pr_warn(".*[^n]\)\("[),]\)/\1\\n\2/' $i
done
Signed-off-by: 's avatarPavel Tikhomirov <ptikhomirov@virtuozzo.com>
Signed-off-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
parent b4ab1d8c
......@@ -137,7 +137,7 @@ int compel_interrupt_task(int pid)
*/
ret = ptrace(PTRACE_INTERRUPT, pid, NULL, NULL);
if (ret < 0) {
pr_warn("SEIZE %d: can't interrupt task: %s", pid, strerror(errno));
pr_warn("SEIZE %d: can't interrupt task: %s\n", pid, strerror(errno));
if (ptrace(PTRACE_DETACH, pid, NULL, NULL))
pr_perror("Unable to detach from %d", pid);
}
......
......@@ -2289,7 +2289,7 @@ out_kill:
kill(root_item->pid->real, SIGKILL);
if (waitpid(root_item->pid->real, &status, 0) < 0)
pr_warn("Unable to wait %d: %s",
pr_warn("Unable to wait %d: %s\n",
root_item->pid->real, strerror(errno));
} else {
struct pstree_item *pi;
......
......@@ -235,7 +235,7 @@ int main(int argc, char *argv[], char *envp[])
opts.restore_detach &&
opts.final_state == TASK_STOPPED &&
opts.shell_job)
pr_warn("Stopped and detached shell job will get SIGHUP from OS.");
pr_warn("Stopped and detached shell job will get SIGHUP from OS.\n");
if (chdir(opts.work_dir)) {
pr_perror("Can't change directory to %s", opts.work_dir);
......
......@@ -1355,7 +1355,7 @@ static int linkat_hard(int odir, char *opath, int ndir, char *npath, uid_t uid,
if (!( (errno == EPERM || errno == EOVERFLOW) && (root_ns_mask & CLONE_NEWUSER) )) {
errno_save = errno;
pr_warn("Can't link %s -> %s", opath, npath);
pr_warn("Can't link %s -> %s\n", opath, npath);
errno = errno_save;
return ret;
}
......
......@@ -52,7 +52,7 @@ int check_namespace_opts(void)
return -1;
}
if (join_ns_flags & CLONE_NEWUSER)
pr_warn("join-ns with user-namespace is not fully tested and dangerous");
pr_warn("join-ns with user-namespace is not fully tested and dangerous\n");
errno = 0;
return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment