zdtm: Add proc-self01 test

Check, that fdstore-keeped user ns files are opened
correct after restore.

Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
Kirill Tkhai 2017-04-01 14:38:06 +03:00 committed by Andrei Vagin
parent ec157994f8
commit d9a785adbb
3 changed files with 7 additions and 0 deletions

View file

@ -116,6 +116,7 @@ TST_NOFILE := \
pdeath_sig \
file_fown \
proc-self \
proc-self01 \
eventfs00 \
signalfd00 \
inotify_irmap \
@ -506,6 +507,7 @@ socket-tcp4v6-closing: CFLAGS += -D ZDTM_IPV4V6
pty-console: CFLAGS += -D ZDTM_DEV_CONSOLE
userns02: CFLAGS += -D USERNS02
proc-self01: override CFLAGS += -D PROC_SELF01
shm-unaligned: CFLAGS += -DZDTM_SHM_UNALIGNED

View file

@ -15,7 +15,11 @@
const char *test_doc = "Check for /proc/self/ns path restore";
const char *test_author = "Cyrill Gorcunov <gorcunov@openvz.org>";
#ifdef PROC_SELF01
const char nspath[] = "/proc/self/ns/user";
#else
const char nspath[] = "/proc/self/ns/net";
#endif
int read_fd_link(int lfd, char *buf, size_t size)
{

View file

@ -0,0 +1 @@
proc-self.c