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

index 58e17fb6a14f1f208b1974082a5661d69c166047..f4e1e9906189d911a609b3ca07e20f133da72166 100644 (file)
@@ -1012,7 +1012,7 @@ static int lxc_attach_pty_mainloop_init(struct lxc_pty *pty,
                return -1;
        }
 
-       ret = lxc_console_mainloop_add(descr, pty);
+       ret = lxc_terminal_mainloop_add(descr, pty);
        if (ret < 0) {
                ERROR("Failed to add handlers to mainloop");
                lxc_mainloop_close(descr);
index e38e2d7b38934bd00b7f068202ffb61bf87b96ca..884be2ff7b434119bf505728e0290d7229bab89c 100644 (file)
@@ -433,7 +433,7 @@ static int lxc_terminal_mainloop_add_peer(struct lxc_pty *console)
        return 0;
 }
 
-int lxc_console_mainloop_add(struct lxc_epoll_descr *descr,
+int lxc_terminal_mainloop_add(struct lxc_epoll_descr *descr,
                             struct lxc_pty *console)
 {
        int ret;
index 91a4ae43b8725eb3c95b7b258f5c27d51cf3b6ba..b7f05f5a4d74cb837d06ac0af7fcd09b1b9011d7 100644 (file)
@@ -114,7 +114,7 @@ extern void lxc_console_free(struct lxc_conf *conf, int fd);
 /*
  * Register pty event handlers in an open mainloop
  */
-extern int  lxc_console_mainloop_add(struct lxc_epoll_descr *, struct lxc_pty *);
+extern int  lxc_terminal_mainloop_add(struct lxc_epoll_descr *, struct lxc_pty *);
 
 /*
  * Handle SIGWINCH events on the allocated ptys.
@@ -153,7 +153,7 @@ extern int lxc_console_set_stdfds(int fd);
 /*
  * Handler for events on the stdin fd of the pty. To be registered via the
  * corresponding functions declared and defined in mainloop.{c,h} or
- * lxc_console_mainloop_add().
+ * lxc_terminal_mainloop_add().
  * This function exits the loop cleanly when an EPOLLHUP event is received.
  */
 extern int lxc_console_cb_tty_stdin(int fd, uint32_t events, void *cbdata,
@@ -162,7 +162,7 @@ extern int lxc_console_cb_tty_stdin(int fd, uint32_t events, void *cbdata,
 /*
  * Handler for events on the master fd of the pty. To be registered via the
  * corresponding functions declared and defined in mainloop.{c,h} or
- * lxc_console_mainloop_add().
+ * lxc_terminal_mainloop_add().
  * This function exits the loop cleanly when an EPOLLHUP event is received.
  */
 extern int lxc_console_cb_tty_master(int fd, uint32_t events, void *cbdata,
@@ -209,7 +209,7 @@ extern struct lxc_tty_state *lxc_terminal_signal_init(int srcfd, int dstfd);
 
 /*
  * Handler for signal events. To be registered via the corresponding functions
- * declared and defined in mainloop.{c,h} or lxc_console_mainloop_add().
+ * declared and defined in mainloop.{c,h} or lxc_terminal_mainloop_add().
  */
 extern int lxc_terminal_signalfd_cb(int fd, uint32_t events, void *cbdata,
                                    struct lxc_epoll_descr *descr);
index ebcd0c27231f17c74710bb241c4abb11d967bf3b..d735082d4c1d570c53faaab5e9bf1841e5881c67 100644 (file)
@@ -531,13 +531,13 @@ int lxc_poll(const char *name, struct lxc_handler *handler)
        if (has_console) {
                struct lxc_pty *console = &handler->conf->console;
 
-               ret = lxc_console_mainloop_add(&descr, console);
+               ret = lxc_terminal_mainloop_add(&descr, console);
                if (ret < 0) {
                        ERROR("Failed to add console handlers to mainloop");
                        goto out_mainloop_console;
                }
 
-               ret = lxc_console_mainloop_add(&descr_console, console);
+               ret = lxc_terminal_mainloop_add(&descr_console, console);
                if (ret < 0) {
                        ERROR("Failed to add console handlers to console mainloop");
                        goto out_mainloop_console;