From 54fc4636f31b28b2ca88054b0522ad17d3bfa87e Mon Sep 17 00:00:00 2001 From: Edward Tomasz Napierala Date: Thu, 26 May 2016 14:21:02 +0000 Subject: [PATCH] Do libxo cleanup even in case of errors. MFC after: 1 month Sponsored by: The FreeBSD Foundation --- usr.bin/iscsictl/iscsictl.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/usr.bin/iscsictl/iscsictl.c b/usr.bin/iscsictl/iscsictl.c index b96c897a4ba1..840ee6c7d696 100644 --- a/usr.bin/iscsictl/iscsictl.c +++ b/usr.bin/iscsictl/iscsictl.c @@ -987,10 +987,11 @@ main(int argc, char **argv) if (error != 0) xo_err(1, "close"); + xo_close_container("iscsictl"); + xo_finish(); + if (failed != 0) return (1); - xo_close_container("iscsictl"); - xo_finish(); return (0); }