/freebsd/tools/regression/capsicum/syscalls/ |
H A D | cap_fcntls_limit.c | 49 CHECK(cap_fcntls_get(fd, &fcntlrights) == 0); in fcntl_tests_0() 50 CHECK(fcntlrights == CAP_FCNTL_ALL); in fcntl_tests_0() 52 CHECK(fcntl(fd, F_GETFD) == 0); in fcntl_tests_0() 53 CHECK(fcntl(fd, F_SETFD, FD_CLOEXEC) == 0); in fcntl_tests_0() 54 CHECK(fcntl(fd, F_GETFD) == FD_CLOEXEC); in fcntl_tests_0() 55 CHECK(fcntl(fd, F_SETFD, 0) == 0); in fcntl_tests_0() 56 CHECK(fcntl(fd, F_GETFD) == 0); in fcntl_tests_0() 58 CHECK(fcntl(fd, F_GETFL) == O_RDWR); in fcntl_tests_0() 59 CHECK(fcntl(fd, F_SETFL, O_NONBLOCK) == 0); in fcntl_tests_0() 60 CHECK(fcnt in fcntl_tests_0() [all...] |
H A D | cap_ioctls_limit.c | 50 CHECK(cap_ioctls_get(fd, NULL, 0) == CAP_IOCTLS_ALL); in ioctl_tests_0() 52 CHECK(fcntl(fd, F_GETFD) == 0); in ioctl_tests_0() 53 CHECK(ioctl(fd, FIOCLEX) == 0); in ioctl_tests_0() 54 CHECK(fcntl(fd, F_GETFD) == FD_CLOEXEC); in ioctl_tests_0() 55 CHECK(ioctl(fd, FIONCLEX) == 0); in ioctl_tests_0() 56 CHECK(fcntl(fd, F_GETFD) == 0); in ioctl_tests_0() 60 CHECK(cap_ioctls_limit(fd, cmds, nitems(cmds)) == 0); in ioctl_tests_0() 62 CHECK(cap_ioctls_get(fd, cmds, nitems(cmds)) == nitems(cmds)); in ioctl_tests_0() 63 CHECK((cmds[0] == FIOCLEX && cmds[1] == FIONCLEX) || in ioctl_tests_0() 67 CHECK(cap_ioctls_limi in ioctl_tests_0() [all...] |
H A D | cap_getmode.c | 52 CHECK(cap_getmode(&mode) == 0); in main() 54 CHECK(mode != 666); in main() 56 CHECK(mode == 0); in main() 60 CHECK(cap_getmode(NULL) == -1); in main() 61 CHECK(errno == EFAULT); in main() 63 CHECK(cap_getmode((void *)(uintptr_t)0xdeadc0de) == -1); in main() 64 CHECK(errno == EFAULT); in main() 73 CHECK(cap_getmode(&mode) == 0); in main() 75 CHECK(mode != 666); in main() 77 CHECK(mod in main() [all...] |
/freebsd/tools/regression/iscsi/ |
H A D | iscsi-test.sh | 114 check() { function 136 check iscontrol -dt $TARGETIP > $TMPDIR/discovered 140 check cmp $TMPDIR/expected $TMPDIR/discovered 146 check iscsictl -Ad $TARGETIP 150 check cmp $TMPDIR/expected $TMPDIR/discovered 152 check iscsictl -Ra 164 check iscsiadm -m discovery -t sendtargets -p $TARGETIP > $TMPDIR/discovered 168 check cmp $TMPDIR/expected $TMPDIR/discovered 174 check iscsiadm add discovery-address $TARGETIP 175 check iscsiadm modify discovery --sendtargets enable [all …]
|
/freebsd/bin/sh/tests/expansion/ |
H A D | arith2.0 | 4 check() { 13 check "v=2" 2 14 check "v" 2 15 check "$(($v))" 2 16 check "v+=1" 3 17 check "v" 3 20 check "4611686018427387904" 4611686018427387904 21 check "0x4000000000000000" 4611686018427387904 22 check "0400000000000000000000" 4611686018427387904 23 check "0x4Ab0000000000000" 5381801554707742720 [all …]
|
H A D | pathname1.0 | 8 check() { 28 check '' '' 29 check 'testdir/b' 'testdir/b' 30 check 'testdir/c' 'testdir/c' 31 check '\*' '*' 32 check '\?' '?' 33 check '*' 'testdir testdir2 testf' 34 check '*""' 'testdir testdir2 testf' 35 check '""*' 'testdir testdir2 testf' 36 check '*/' 'testdir/ testdir2/' [all …]
|
H A D | cmdsubst2.0 | 4 check() { 11 check '`echo /et[c]/` = "/etc/"' 12 check '`printf /var/empty%s /et[c]/` = "/var/empty/etc/"' 13 check '"`echo /et[c]/`" = "/etc/"' 14 check '`echo "/et[c]/"` = "/etc/"' 15 check '`printf /var/empty%s "/et[c]/"` = "/var/empty/et[c]/"' 16 check '`printf /var/empty/%s \"/et[c]/\"` = "/var/empty/\"/et[c]/\""' 17 check '"`echo \"/et[c]/\"`" = "/et[c]/"' 18 check '"`echo "/et[c]/"`" = "/et[c]/"' 19 check '`echo $$` = $$' [all …]
|
H A D | cmdsubst1.0 | 4 check() { 11 check '"$(echo abcde)" = "abcde"' 12 check '"$(echo abcde; :)" = "abcde"' 14 check '"$(printf abcde)" = "abcde"' 15 check '"$(printf abcde; :)" = "abcde"' 18 check '-n "$(umask)"' 19 check '-n "$(umask; :)"' 20 check '-n "$(umask 2>&1)"' 21 check '-n "$(umask 2>&1; :)"' 24 check '-n "$(times)"' [all …]
|
H A D | arith10.0 | 4 check() { 13 check "0 && 0 / 0" 0 14 check "1 || 0 / 0" 1 15 check "0 && (ro = 2)" 0 16 check "ro" 4 17 check "1 || (ro = -1)" 1 18 check "ro" 4 19 check "0 && (rw += 1)" 0 20 check "rw" 1 21 check "1 || (rw += 1)" 1 [all …]
|
H A D | arith1.0 | 4 check() { 11 check "0&&0" 0 12 check "1&&0" 0 13 check "0&&1" 0 14 check "1&&1" 1 15 check "2&&2" 1 16 check "1&&2" 1 17 check "1<<40&&1<<40" 1 18 check "1<<40&&4" 1 20 check "0||0" 0 [all …]
|
/freebsd/contrib/netbsd-tests/include/sys/ |
H A D | t_cdefs.c | 75 #define CHECK(a, b) ATF_REQUIRE(__type_min(a) == s[b].min); \ in ATF_TC_BODY() macro 78 CHECK(signed char, 0); in ATF_TC_BODY() 79 CHECK(signed short, 1); in ATF_TC_BODY() 80 CHECK(signed int, 2); in ATF_TC_BODY() 81 CHECK(signed long, 3); in ATF_TC_BODY() 82 CHECK(signed long long, 4); in ATF_TC_BODY() 83 #undef CHECK in ATF_TC_BODY() 94 #define CHECK(a, b) ATF_REQUIRE(__type_min(a) == u[b].min); \ in ATF_TC_BODY() macro 97 CHECK(unsigned char, 0); in ATF_TC_BODY() 98 CHECK(unsigned short, 1); in ATF_TC_BODY() [all …]
|
/freebsd/usr.bin/bmake/tests/execution/joberr/ |
H A D | expected.stdout.1 | 2 *** [do-check-joberr] Error code 1 4 *** [do-check-joberr] Error code 1 6 *** [do-check-joberr] Error code 1 8 *** [do-check-joberr] Error code 1 10 *** [do-check-joberr] Error code 1 12 *** [do-check-joberr] Error code 1 14 *** [do-check-joberr] Error code 1 16 *** [do-check-joberr] Error code 1 18 *** [do-check-joberr] Error code 1 20 *** [do-check-joberr] Error code 1 [all …]
|
/freebsd/contrib/netbsd-tests/bin/sh/ |
H A D | t_fsplit.sh | 45 check() function 51 (*) atf_fail "Internal test error, $# args to check test ${TEST}";; 93 check 'for f in $x; do echo x${f}y; done' '' 102 # Check that IFS is applied to text from ${x-...} unless it is inside 104 check 'set -- ${x-a b c}; echo $#' 3 106 check 'set -- ${x-"a b" c}; echo $#' 2 107 check 'set -- ${x-a "b c"}; echo $#' 2 108 check 'set -- ${x-"a b c"}; echo $#' 1 110 check "set -- \${x-'a b' c}; echo \$#" 2 111 check "set -- \${x-a 'b c'}; echo \$#" 2 [all …]
|
H A D | t_here.sh | 41 check() function 128 check 'x=`cat <<EOF'$nl'text'${nl}EOF$nl'`; echo $x' 'text' 0 129 check 'x=`cat <<\EOF'$nl'text'${nl}EOF$nl'`; echo $x' 'text' 0 131 check "y=${y};"'x=`cat <<EOF'$nl'te${y}t'${nl}EOF$nl'`; echo $x' \ 133 check "y=${y};"'x=`cat <<\EOF'$nl'te${y}t'${nl}EOF$nl'`; echo $x' \ 135 check "y=${y};"'x=`cat <<"EOF"'$nl'te${y}t'${nl}EOF$nl'`; echo $x' \ 137 check "y=${y};"'x=`cat <<'"'EOF'"$nl'te${y}t'${nl}EOF$nl'`; echo $x' \ 140 # check that quotes in the here doc survive and cause no problems 141 check "cat <<EOF${nl}te'xt${nl}EOF$nl" "te'xt" 0 142 check "cat <<\EOF${nl}te'xt${nl}EOF$nl" "te'xt" 0 [all …]
|
/freebsd/contrib/unbound/util/ |
H A D | fptr_wlist.h | 39 * This file contains functions that check function pointers. 64 * Macro to perform an assertion check for fptr wlist checks. 65 * Does not get disabled in optimize mode. Check adds security by layers. 78 * Check function pointer whitelist for comm_point callback values. 80 * @param fptr: function pointer to check. 86 * Check function pointer whitelist for raw comm_point callback values. 88 * @param fptr: function pointer to check. 94 * Check function pointer whitelist for comm_timer callback values. 96 * @param fptr: function pointer to check. 102 * Check function pointer whitelist for comm_signal callback values. [all …]
|
/freebsd/contrib/ntp/libjsmn/ |
H A D | jsmn_test.c | 14 /* Check single condition */ 15 #define check(cond) do { if (!(cond)) fail(); } while (0) macro 53 check(r >= 0); in test_empty() 54 check(t[0].type == JSMN_OBJECT); in test_empty() 55 check(t[0].start == 0 && t[0].end == 2); in test_empty() 60 check(r >= 0); in test_empty() 61 check(t[0].type == JSMN_ARRAY); in test_empty() 62 check(t[0].start == 0 && t[0].end == 2); in test_empty() 67 check(r >= 0); in test_empty() 68 check(t[0].type == JSMN_OBJECT && t[0].start == 0 && t[0].end == 8); in test_empty() [all …]
|
/freebsd/crypto/heimdal/kadmin/ |
H A D | rpc.c | 44 #define CHECK(x) \ macro 55 #define INSIST(x) CHECK(!(x)) 237 CHECK(read_data(sp, msg, len)); in collect_framents() 307 CHECK(krb5_ret_uint32(sp, &gcred->version)); in ret_gcred() 308 CHECK(krb5_ret_uint32(sp, &gcred->proc)); in ret_gcred() 309 CHECK(krb5_ret_uint32(sp, &gcred->seq_num)); in ret_gcred() 310 CHECK(krb5_ret_uint32(sp, &gcred->service)); in ret_gcred() 311 CHECK(ret_data_xdr(sp, &gcred->handle)); in ret_gcred() 357 CHECK(ret_data_xdr(sp, &c)); in ret_string_xdr() 374 CHECK(krb5_unparse_name(contextp, p, &str)); in store_principal_xdr() [all …]
|
/freebsd/contrib/libarchive/libarchive/test/ |
H A D | test_write_format_zip_entry_size_unset.c | 116 /* Check for end of central directory signature */ in verify_contents() 118 /* Check for number of disk */ in verify_contents() 120 /* Check for disk where central directory starts */ in verify_contents() 122 /* Check for number of central directory records on disk */ in verify_contents() 124 /* Check for total number of central directory records */ in verify_contents() 126 /* Check for size of central directory and offset in verify_contents() 129 /* Check for empty comment length */ in verify_contents() 135 /* Check for entry in central directory signature */ in verify_contents() 137 /* Check for version used to write entry */ in verify_contents() 139 /* Check for version needed to extract entry */ in verify_contents() [all …]
|
/freebsd/crypto/heimdal/lib/kadm5/ |
H A D | marshall.c | 37 #define CHECK(e) do { if (e) return EINVAL; } while (0) macro 44 CHECK(krb5_store_int32(sp, key->key_data_ver)); in kadm5_store_key_data() 45 CHECK(krb5_store_int32(sp, key->key_data_kvno)); in kadm5_store_key_data() 46 CHECK(krb5_store_int32(sp, key->key_data_type[0])); in kadm5_store_key_data() 49 CHECK(krb5_store_data(sp, c)); in kadm5_store_key_data() 50 CHECK(krb5_store_int32(sp, key->key_data_type[1])); in kadm5_store_key_data() 53 CHECK(krb5_store_data(sp, c)); in kadm5_store_key_data() 99 CHECK(krb5_store_int32(sp, tl->tl_data_type)); in kadm5_store_tl_data() 102 CHECK(krb5_store_data(sp, c)); in kadm5_store_tl_data() 114 CHECK(krb5_ret_data(sp, &c)); in kadm5_ret_tl_data() [all …]
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/ |
H A D | libzfs_input_check.c | 309 fnvlist_add_string(required, "message", "input check"); in test_log_history() 941 * Canonical reference check of /dev/zfs ioctl numbers. 949 #define CHECK(expr) do { \ in validate_ioc_values() macro 956 CHECK(ZFS_IOC_BASE + 0 == ZFS_IOC_POOL_CREATE); in validate_ioc_values() 957 CHECK(ZFS_IOC_BASE + 1 == ZFS_IOC_POOL_DESTROY); in validate_ioc_values() 958 CHECK(ZFS_IOC_BASE + 2 == ZFS_IOC_POOL_IMPORT); in validate_ioc_values() 959 CHECK(ZFS_IOC_BASE + 3 == ZFS_IOC_POOL_EXPORT); in validate_ioc_values() 960 CHECK(ZFS_IOC_BASE + 4 == ZFS_IOC_POOL_CONFIGS); in validate_ioc_values() 961 CHECK(ZFS_IOC_BASE + 5 == ZFS_IOC_POOL_STATS); in validate_ioc_values() 962 CHECK(ZFS_IOC_BASE + 6 == ZFS_IOC_POOL_TRYIMPORT); in validate_ioc_values() [all …]
|
/freebsd/crypto/openssl/test/recipes/ |
H A D | 15-test_ecparam.t | 32 my $valid = shift; # Check should pass or fail? 64 subtest "Check loading valid parameters by ecparam with -check" => sub { 66 checkload(\@valid, 1, "ecparam", "-check"); 69 subtest "Check loading valid parameters by ecparam with -check_named" => sub { 74 subtest "Check loading valid parameters by pkeyparam with -check" => sub { 76 checkload(\@valid, 1, "pkeyparam", "-check"); 79 subtest "Check loading non-canonically encoded parameters by ecparam with -check" => sub { 81 checkload(\@noncanon, 1, "ecparam", "-check"); 84 subtest "Check loading non-canonically encoded parameters by ecparam with -check_named" => sub { 89 subtest "Check loading non-canonically encoded parameters by pkeyparam with -check" => sub { [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/IR/ |
H A D | Verifier.cpp | 282 /// A check failed, so printout out the condition and the message. 292 /// A check failed (with values to print). 303 /// A debug info check failed. 311 /// A debug info check failed (with values to print). 658 #define Check(C, ...) \ macro 704 Check(I.getOperand(i) != nullptr, "Operand is null", &I); in visit() 727 Check(!GV.isDeclaration() || GV.hasValidDeclarationLinkage(), in visitGlobalValue() 733 Check(A->value() <= Value::MaximumAlignment, in visitGlobalValue() 739 Check(Associated->getNumOperands() == 1, in visitGlobalValue() 742 Check(Op, "associated metadata must have a global value", GO, Associated); in visitGlobalValue() [all …]
|
/freebsd/crypto/heimdal/lib/ntlm/ |
H A D | ntlm.c | 110 #define CHECK(f, e) \ macro 222 CHECK(krb5_ret_uint16(sp, &buf->length), 0); in ret_sec_buffer() 223 CHECK(krb5_ret_uint16(sp, &buf->allocated), 0); in ret_sec_buffer() 224 CHECK(krb5_ret_uint32(sp, &buf->offset), 0); in ret_sec_buffer() 233 CHECK(krb5_store_uint16(sp, buf->length), 0); in store_sec_buffer() 234 CHECK(krb5_store_uint16(sp, buf->allocated), 0); in store_sec_buffer() 235 CHECK(krb5_store_uint32(sp, buf->offset), 0); in store_sec_buffer() 266 CHECK(krb5_storage_read(sp, *s, len), len); in ret_string() 293 CHECK(krb5_storage_seek(sp, desc->offset, SEEK_SET), desc->offset); in ret_sec_string() 294 CHECK(ret_string(sp, ucs2, desc->length, s), 0); in ret_sec_string() [all …]
|
/freebsd/tools/regression/security/cap_test/ |
H A D | cap_test_capabilities.c | 129 CHECK(cap_getrights(fd_cap, &erights) == 0); in try_file_ops() 130 CHECK(rights == erights); in try_file_ops() 132 CHECK(cap_getrights(fd_capcap, &erights) == 0); in try_file_ops() 133 CHECK(rights == erights); in try_file_ops() 134 CHECK(fd_capcap != fd_cap); in try_file_ops() 136 CHECK(cap_getrights(dfd_cap, &erights) == 0); in try_file_ops() 137 CHECK(rights == erights); in try_file_ops() 151 CHECK(ssize == ssize2); in try_file_ops() 187 CHECK(ret == -1 || close(ret) == 0); in try_file_ops() 188 CHECK(ret == -1 || unlinkat(dirfd, "cap_create", 0) == 0); in try_file_ops() [all …]
|
/freebsd/bin/sh/tests/builtins/ |
H A D | builtin1.0 | 4 check() { 14 check '"$(builtin pwd)" = "$(pwd)"' 15 check '-z "$(builtin :)"' 16 check '-z "$(builtin true)"' 17 check '-z "$( (builtin nosuchtool) 2>/dev/null)"' 18 check '-z "$(builtin nosuchtool 2>/dev/null)"' 19 check '-z "$(builtin nosuchtool 2>/dev/null; :)"' 20 check '-z "$( (builtin ls) 2>/dev/null)"' 21 check '-z "$(builtin ls 2>/dev/null)"' 22 check '-z "$(builtin ls 2>/dev/null; :)"' [all …]
|