]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
console: lxc_terminal_free()
authorChristian Brauner <christian.brauner@ubuntu.com>
Tue, 27 Feb 2018 15:42:30 +0000 (16:42 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Tue, 27 Feb 2018 21:18:13 +0000 (22:18 +0100)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/commands.c
src/lxc/console.c
src/lxc/console.h

index 86fcf3a4f8a5c56c3ab005a86cd02301ff65d751..e7fe012a569ed4de20631e8dcf1920c45c1ea628 100644 (file)
@@ -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);
index 60d471dc8c911fe5123114a8d782617de9d3f301..d8820aa99be9e83cdb9dc93fa5eb7ea35655aca2 100644 (file)
@@ -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;
index a64e7c254488f656454c7886c40a8018a216228b..d0d7d924149f102e495e20ddf2bced4960855ded 100644 (file)
@@ -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