[CRIU] [PATCH 01/20] compel: remove unneeded argc check

Kir Kolyshkin kir at openvz.org
Thu Dec 8 01:44:14 PST 2016


Checks for a number of arguments are to be done after option parsing.

With this patch, compel -V now works.

Signed-off-by: Kir Kolyshkin <kir at openvz.org>
---
 compel/src/main.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/compel/src/main.c b/compel/src/main.c
index 3d18d74..a54aba7 100644
--- a/compel/src/main.c
+++ b/compel/src/main.c
@@ -137,9 +137,6 @@ int main(int argc, char *argv[])
 		{ },
 	};
 
-	if (argc < 3)
-		goto usage;
-
 	while (1) {
 		idx = -1;
 		opt = getopt_long(argc, argv, short_opts, long_opts, &idx);
-- 
2.7.4



More information about the CRIU mailing list