mirror of
https://github.com/checkpoint-restore/criu
synced 2025-08-31 06:15:24 +00:00
cr: Fix namespaces restore from older images
In old images we had no clue whether the root task is to be created in new namespaces. Remember using the --namespaces option for explicitl specification of this fact. Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
@@ -284,6 +284,11 @@ int check_ns_ids(struct pstree_item *item)
|
||||
struct pstree_item *p = item->parent;
|
||||
|
||||
if (!p) {
|
||||
if (!root_ids) {
|
||||
current_ns_mask = opts.rst_namespaces_flags;
|
||||
return 0;
|
||||
}
|
||||
|
||||
current_ns_mask = get_clone_mask(item->ids, root_ids);
|
||||
pr_info("Will restore in %lx namespaces\n", current_ns_mask);
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user