From f57e397e96fbf9d2985392ef10d3b0a6ce212ffd Mon Sep 17 00:00:00 2001 From: Gao feng Date: Fri, 23 Dec 2016 16:15:30 +0800 Subject: [PATCH] remove some logs Signed-off-by: Gao feng --- src/container.c | 2 -- src/exec.c | 10 +++------- src/init.c | 1 - src/net.c | 1 - 4 files changed, 3 insertions(+), 11 deletions(-) diff --git a/src/container.c b/src/container.c index 18f449ec..ad4a1f3c 100644 --- a/src/container.c +++ b/src/container.c @@ -550,8 +550,6 @@ static int hyper_setup_container_rootfs(void *data) goto fail; } - fprintf(stdout, "container root directory %s\n", root); - if (container->fstype) { char dev[128]; char *options = NULL; diff --git a/src/exec.c b/src/exec.c index 84b1f887..434e3120 100644 --- a/src/exec.c +++ b/src/exec.c @@ -67,31 +67,28 @@ static int hyper_send_exec_code(struct hyper_exec *exec) { static void pts_hup(struct hyper_event *de, int efd, struct hyper_exec *exec) { - fprintf(stdout, "%s, seq %" PRIu64"\n", __func__, exec->seq); - hyper_event_hup(de, efd); - hyper_release_exec(exec); } static void stdin_hup(struct hyper_event *de, int efd) { struct hyper_exec *exec = container_of(de, struct hyper_exec, stdinev); - fprintf(stdout, "%s\n", __func__); + fprintf(stdout, "%s, seq %" PRIu64", id %s\n", __func__, exec->seq, exec->id); return pts_hup(de, efd, exec); } static void stdout_hup(struct hyper_event *de, int efd) { struct hyper_exec *exec = container_of(de, struct hyper_exec, stdoutev); - fprintf(stdout, "%s\n", __func__); + fprintf(stdout, "%s, seq %" PRIu64", id %s\n", __func__, exec->seq, exec->id); return pts_hup(de, efd, exec); } static void stderr_hup(struct hyper_event *de, int efd) { struct hyper_exec *exec = container_of(de, struct hyper_exec, stderrev); - fprintf(stdout, "%s\n", __func__); + fprintf(stdout, "%s, seq %" PRIu64", id %s\n", __func__, exec->seq, exec->id); return pts_hup(de, efd, exec); } @@ -802,7 +799,6 @@ static int hyper_kill_container_processes(struct hyper_container *c) { if (st.st_ino != st1.st_ino) continue; - fprintf(stdout, "kill process of container %d\n", pid); kill(pid, SIGKILL); loop = 1; } diff --git a/src/init.c b/src/init.c index 3b80ba99..3825b755 100644 --- a/src/init.c +++ b/src/init.c @@ -164,7 +164,6 @@ static void hyper_term_all(struct hyper_pod *pod) fprintf(stdout, "Sending SIGTERM\n"); for (--index; index >= 0; --index) { - fprintf(stdout, "kill process %d\n", pids[index]); kill(pids[index], SIGTERM); } diff --git a/src/net.c b/src/net.c index 965462c0..e896523f 100644 --- a/src/net.c +++ b/src/net.c @@ -166,7 +166,6 @@ static int hyper_get_ifindex(char *nic) int fd, ifindex = -1; char path[512], buf[8]; - fprintf(stdout, "net device %s\n", nic); sprintf(path, "/sys/class/net/%s/ifindex", nic); fprintf(stdout, "net device sys path is %s\n", path);