From: Christian Brauner Date: Tue, 27 Feb 2018 15:42:30 +0000 (+0100) Subject: console: lxc_terminal_free() X-Git-Tag: lxc-3.0.0.beta1~5^2~28 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3dfe6f8dacfafe45884313d79d10183bbd0703c4;p=thirdparty%2Flxc.git console: lxc_terminal_free() Signed-off-by: Christian Brauner --- diff --git a/src/lxc/commands.c b/src/lxc/commands.c index 86fcf3a4f..e7fe012a5 100644 --- a/src/lxc/commands.c +++ b/src/lxc/commands.c @@ -757,7 +757,7 @@ static int lxc_cmd_console_callback(int fd, struct lxc_cmd_req *req, ret = lxc_abstract_unix_send_fds(fd, &masterfd, 1, &rsp, sizeof(rsp)); if (ret < 0) { ERROR("Failed to send tty to client"); - lxc_console_free(handler->conf, fd); + lxc_terminal_free(handler->conf, fd); goto out_close; } @@ -1080,7 +1080,7 @@ static void lxc_cmd_fd_cleanup(int fd, struct lxc_handler *handler, struct lxc_state_client *client; struct lxc_list *cur, *next; - lxc_console_free(handler->conf, fd); + lxc_terminal_free(handler->conf, fd); lxc_mainloop_del_handler(descr, fd); if (cmd != LXC_CMD_ADD_STATE_CLIENT) { close(fd); diff --git a/src/lxc/console.c b/src/lxc/console.c index 60d471dc8..d8820aa99 100644 --- a/src/lxc/console.c +++ b/src/lxc/console.c @@ -617,7 +617,7 @@ out: return masterfd; } -void lxc_console_free(struct lxc_conf *conf, int fd) +void lxc_terminal_free(struct lxc_conf *conf, int fd) { int i; struct lxc_tty_info *tty_info = &conf->tty_info; diff --git a/src/lxc/console.h b/src/lxc/console.h index a64e7c254..d0d7d9241 100644 --- a/src/lxc/console.h +++ b/src/lxc/console.h @@ -101,7 +101,7 @@ extern int lxc_console_create(struct lxc_conf *); extern void lxc_console_delete(struct lxc_pty *); /* - * lxc_console_free: mark the console or a tty as unallocated, free any + * lxc_terminal_free: mark the console or a tty as unallocated, free any * resources allocated by lxc_terminal_allocate(). * * @conf : the configuration of the container whose tty was closed @@ -109,7 +109,7 @@ extern void lxc_console_delete(struct lxc_pty *); * the console or tty is no longer in use. this is used to match * which console/tty is being freed. */ -extern void lxc_console_free(struct lxc_conf *conf, int fd); +extern void lxc_terminal_free(struct lxc_conf *conf, int fd); /* * Register pty event handlers in an open mainloop