]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
tools: lxc-wait: share internal API symbols
author2xsec <dh48.jeong@samsung.com>
Thu, 28 Jun 2018 14:07:01 +0000 (23:07 +0900)
committer2xsec <dh48.jeong@samsung.com>
Thu, 28 Jun 2018 14:07:01 +0000 (23:07 +0900)
Signed-off-by: 2xsec <dh48.jeong@samsung.com>
src/lxc/Makefile.am
src/lxc/tools/lxc_wait.c

index 8324eb1fe225ed2e367a853ee209d76cf1c64632..81c0d17ba49d25b18734256e7f9fdc22a5a747f1 100644 (file)
@@ -283,7 +283,7 @@ lxc_stop_SOURCES = tools/lxc_stop.c tools/arguments.c
 lxc_top_SOURCES = tools/lxc_top.c tools/arguments.c tools/tool_utils.c
 lxc_unfreeze_SOURCES = tools/lxc_unfreeze.c tools/arguments.c
 lxc_unshare_SOURCES = tools/lxc_unshare.c tools/arguments.c tools/tool_utils.c
-lxc_wait_SOURCES = tools/lxc_wait.c tools/arguments.c tools/tool_utils.c
+lxc_wait_SOURCES = tools/lxc_wait.c tools/arguments.c
 lxc_create_SOURCES = tools/lxc_create.c tools/arguments.c tools/tool_utils.c
 lxc_snapshot_SOURCES = tools/lxc_snapshot.c tools/arguments.c tools/tool_utils.c
 lxc_checkpoint_SOURCES = tools/lxc_checkpoint.c tools/arguments.c tools/tool_utils.c
index 346c546ee09f79ad18cb5847f64f6849f0daefe7..01ea3fa515886764953c7220c9d5465452b2b1b7 100644 (file)
 #include <lxc/lxccontainer.h>
 
 #include "arguments.h"
-#include "tool_utils.h"
+#include "log.h"
+
+lxc_log_define(lxc_wait, lxc);
 
 static int my_checker(const struct lxc_arguments *args)
 {
        if (!args->states) {
-               lxc_error(args, "missing state option to wait for.");
+               ERROR("Missing state option to wait for.");
                return -1;
        }
 
@@ -107,7 +109,7 @@ int main(int argc, char *argv[])
                exit(EXIT_FAILURE);
 
        if (!c->may_control(c)) {
-               lxc_error(&my_args, "Insufficent privileges to control %s", c->name);
+               ERROR("Insufficent privileges to control %s", c->name);
                lxc_container_put(c);
                exit(EXIT_FAILURE);
        }
@@ -116,14 +118,14 @@ int main(int argc, char *argv[])
                c->clear_config(c);
 
                if (!c->load_config(c, my_args.rcfile)) {
-                       lxc_error(&my_args, "Failed to load rcfile");
+                       ERROR("Failed to load rcfile");
                        lxc_container_put(c);
                        exit(EXIT_FAILURE);
                }
 
                c->configfile = strdup(my_args.rcfile);
                if (!c->configfile) {
-                       lxc_error(&my_args, "Out of memory setting new config filename");
+                       ERROR("Out of memory setting new config filename");
                        lxc_container_put(c);
                        exit(EXIT_FAILURE);
                }