diff --git a/test/zdtm/live/static/mountpoints.c b/test/zdtm/live/static/mountpoints.c index 2869febae..c921d7c25 100644 --- a/test/zdtm/live/static/mountpoints.c +++ b/test/zdtm/live/static/mountpoints.c @@ -76,7 +76,6 @@ int main(int argc, char **argv) int fd, tmpfs_fd, have_bfmtm = 0; unsigned fs_cnt, fs_cnt_last = 0; struct ns_exec_args args; - mode_t old_mask; pid_t pid = -1; test_init(argc, argv); @@ -266,17 +265,6 @@ done: "binfmt_misc", 0, "") == 0) have_bfmtm = 1; - unlink("/dev/null"); - /* - * Clear umask first, create readable & writeable /dev/null, - * and change it back. This is done to ensure that file mode - * creation mask will not impede it to create file that grants - * read and write permission to all users. - */ - old_mask = umask(0); - mknod("/dev/null", 0777 | S_IFCHR, makedev(1, 3)); - umask(old_mask); - fd = open(MPTS_ROOT"/kernel/meminfo", O_RDONLY); if (fd == -1) return 1;