Lines Matching refs:fd2
572 int r, fd2; in mfd_assert_shrink() local
582 fd2 = mfd_assert_open(fd, in mfd_assert_shrink()
585 close(fd2); in mfd_assert_shrink()
954 int fd, fd2; in test_seal_future_write() local
975 fd2 = mfd_assert_reopen_fd(fd); in test_seal_future_write()
977 mfd_assert_read(fd2); in test_seal_future_write()
978 mfd_assert_read_shared(fd2); in test_seal_future_write()
979 mfd_fail_write(fd2); in test_seal_future_write()
984 close(fd2); in test_seal_future_write()
1427 int fd, fd2; in test_share_dup() local
1436 fd2 = mfd_assert_dup(fd); in test_share_dup()
1437 mfd_assert_has_seals(fd2, 0); in test_share_dup()
1441 mfd_assert_has_seals(fd2, F_SEAL_WRITE); in test_share_dup()
1443 mfd_assert_add_seals(fd2, F_SEAL_SHRINK); in test_share_dup()
1445 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK); in test_share_dup()
1449 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK | F_SEAL_SEAL); in test_share_dup()
1452 mfd_fail_add_seals(fd2, F_SEAL_GROW); in test_share_dup()
1454 mfd_fail_add_seals(fd2, F_SEAL_SEAL); in test_share_dup()
1456 close(fd2); in test_share_dup()
1503 int fd, fd2; in test_share_open() local
1512 fd2 = mfd_assert_open(fd, O_RDWR, 0); in test_share_open()
1515 mfd_assert_has_seals(fd2, F_SEAL_WRITE); in test_share_open()
1517 mfd_assert_add_seals(fd2, F_SEAL_SHRINK); in test_share_open()
1519 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK); in test_share_open()
1522 fd = mfd_assert_open(fd2, O_RDONLY, 0); in test_share_open()
1526 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK); in test_share_open()
1528 close(fd2); in test_share_open()
1529 fd2 = mfd_assert_open(fd, O_RDWR, 0); in test_share_open()
1531 mfd_assert_add_seals(fd2, F_SEAL_SEAL); in test_share_open()
1533 mfd_assert_has_seals(fd2, F_SEAL_WRITE | F_SEAL_SHRINK | F_SEAL_SEAL); in test_share_open()
1535 close(fd2); in test_share_open()