Lines Matching refs:fd2
390 int r, fd2; in mfd_assert_shrink() local
400 fd2 = mfd_assert_open(fd, in mfd_assert_shrink()
403 close(fd2); in mfd_assert_shrink()
733 int fd, fd2; in test_share_dup() local
740 fd2 = mfd_assert_dup(fd); in test_share_dup()
741 mfd_assert_has_seals(fd2, 0); in test_share_dup()
745 mfd_assert_has_seals(fd2, F_SEAL_WRITE); in test_share_dup()
747 mfd_assert_add_seals(fd2, F_SEAL_SHRINK); in test_share_dup()
749 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK); in test_share_dup()
753 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK | F_SEAL_SEAL); in test_share_dup()
756 mfd_fail_add_seals(fd2, F_SEAL_GROW); in test_share_dup()
758 mfd_fail_add_seals(fd2, F_SEAL_SEAL); in test_share_dup()
760 close(fd2); in test_share_dup()
805 int fd, fd2; in test_share_open() local
812 fd2 = mfd_assert_open(fd, O_RDWR, 0); in test_share_open()
815 mfd_assert_has_seals(fd2, F_SEAL_WRITE); in test_share_open()
817 mfd_assert_add_seals(fd2, F_SEAL_SHRINK); in test_share_open()
819 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK); in test_share_open()
822 fd = mfd_assert_open(fd2, O_RDONLY, 0); in test_share_open()
826 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK); in test_share_open()
828 close(fd2); in test_share_open()
829 fd2 = mfd_assert_open(fd, O_RDWR, 0); in test_share_open()
831 mfd_assert_add_seals(fd2, F_SEAL_SEAL); in test_share_open()
833 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK | F_SEAL_SEAL); in test_share_open()
835 close(fd2); in test_share_open()