From 5f59a7cc3507c9d3b91ef851ebb0d32a6aa47a8b Mon Sep 17 00:00:00 2001 From: Radostin Stoyanov Date: Tue, 22 Dec 2020 12:26:03 +0000 Subject: [PATCH] criu-ns: Add unsupported msg for restore-sibling Currently criu-ns does not support the --restore-sibling option. Signed-off-by: Radostin Stoyanov --- scripts/criu-ns | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/criu-ns b/scripts/criu-ns index 0c753347b..68ced5ec8 100755 --- a/scripts/criu-ns +++ b/scripts/criu-ns @@ -83,13 +83,16 @@ def run_criu(args): def wrap_restore(): + restore_args = sys.argv[1:] + if '--restore-sibling' in restore_args: + raise OSError(errno.EINVAL, "--restore-sibling is not supported") + # Unshare pid and mount namespaces if _unshare(CLONE_NEWNS | CLONE_NEWPID) != 0: _errno = ctypes.get_errno() raise OSError(_errno, errno.errorcode[_errno]) restore_detached = False - restore_args = sys.argv[1:] if '-d' in restore_args: restore_detached = True restore_args.remove('-d')