core: Init fdstore even earlier

Next patch will move SELF_STDIN_OFF sfd to fdstore.
This patch moves fdstore_init() before tty_prep_fds().

v4: New

Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
This commit is contained in:
Kirill Tkhai 2018-01-10 17:00:32 +03:00 committed by Andrei Vagin
parent 76b8ab3500
commit 847e585f68

View file

@ -2204,9 +2204,6 @@ static int restore_root_task(struct pstree_item *init)
if (prepare_userns_hook())
return -1;
if (fdstore_init())
return -1;
if (prepare_namespace_before_tasks())
return -1;
@ -2533,6 +2530,9 @@ int cr_restore_tasks(void)
if (prepare_pstree() < 0)
goto err;
if (fdstore_init())
goto err;
if (crtools_prepare_shared() < 0)
goto err;