[lxc-devel] [lxc/master] lxc/tools/lxc/destory: Restores error message on container destroy

tomponline on Github lxc-bot at linuxcontainers.org
Mon Oct 14 09:13:43 UTC 2019


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 498 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20191014/db5de6fb/attachment.bin>
-------------- next part --------------
From 87f2b80c9b81d925284afc355552ff9a37811de6 Mon Sep 17 00:00:00 2001
From: Thomas Parrott <thomas.parrott at canonical.com>
Date: Mon, 14 Oct 2019 10:10:21 +0100
Subject: [PATCH] lxc/tools/lxc/destory: Restores error message on container
 destroy

Partially reverts 65b92ea5fcab559fd21be2685bd2f15ef6d33532 so that trying to destroy a non-existent container gives an error message.

Signed-off-by: Thomas Parrott <thomas.parrott at canonical.com>
---
 src/lxc/tools/lxc_destroy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lxc/tools/lxc_destroy.c b/src/lxc/tools/lxc_destroy.c
index 9fb511e046..d1c6cc6207 100644
--- a/src/lxc/tools/lxc_destroy.c
+++ b/src/lxc/tools/lxc_destroy.c
@@ -256,7 +256,7 @@ int main(int argc, char *argv[])
 	}
 
 	if (!c->is_defined(c)) {
-		INFO("Container %s not found.", my_args.name);
+		ERROR("Container is not defined");
 		lxc_container_put(c);
 		exit(EXIT_FAILURE);
 	}


More information about the lxc-devel mailing list