Commit c3e13372 by Clement Calmels Committed by Daniel Lezcano

Remove useless lines

parent 9d7f9e52
...@@ -158,7 +158,6 @@ int lxc_poll(const char *name, struct lxc_handler *handler) ...@@ -158,7 +158,6 @@ int lxc_poll(const char *name, struct lxc_handler *handler)
{ {
int sigfd = handler->sigfd; int sigfd = handler->sigfd;
int pid = handler->pid; int pid = handler->pid;
int ret = -1;
struct lxc_epoll_descr descr; struct lxc_epoll_descr descr;
if (lxc_mainloop_open(&descr)) { if (lxc_mainloop_open(&descr)) {
...@@ -174,16 +173,13 @@ int lxc_poll(const char *name, struct lxc_handler *handler) ...@@ -174,16 +173,13 @@ int lxc_poll(const char *name, struct lxc_handler *handler)
if (lxc_command_mainloop_add(name, &descr, handler)) if (lxc_command_mainloop_add(name, &descr, handler))
goto out_mainloop_open; goto out_mainloop_open;
ret = lxc_mainloop(&descr); return lxc_mainloop(&descr);
out:
return ret;
out_mainloop_open: out_mainloop_open:
lxc_mainloop_close(&descr); lxc_mainloop_close(&descr);
out_sigfd: out_sigfd:
close(sigfd); close(sigfd);
goto out; return -1;
} }
static int fdname(int fd, char *name, size_t size) static int fdname(int fd, char *name, size_t size)
...@@ -271,10 +267,7 @@ struct lxc_handler *lxc_init(const char *name, struct lxc_conf *conf) ...@@ -271,10 +267,7 @@ struct lxc_handler *lxc_init(const char *name, struct lxc_conf *conf)
LXC_TTY_ADD_HANDLER(SIGINT); LXC_TTY_ADD_HANDLER(SIGINT);
LXC_TTY_ADD_HANDLER(SIGQUIT); LXC_TTY_ADD_HANDLER(SIGQUIT);
out: INFO("'%s' is initialized", name);
if (handler)
INFO("'%s' is initialized", name);
return handler; return handler;
out_delete_tty: out_delete_tty:
...@@ -283,8 +276,7 @@ out_aborting: ...@@ -283,8 +276,7 @@ out_aborting:
lxc_set_state(name, handler, ABORTING); lxc_set_state(name, handler, ABORTING);
out_free: out_free:
free(handler); free(handler);
handler = NULL; return NULL;
goto out;
} }
void lxc_fini(const char *name, struct lxc_handler *handler) void lxc_fini(const char *name, struct lxc_handler *handler)
......
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