| /freebsd-12.1/tests/sys/fs/fusefs/ |
| H A D | statfs.cc | 48 struct statfs statbuf; in TEST_F() local 67 struct statfs statbuf; in TEST_F() local 76 EXPECT_EQ(getuid(), statbuf.f_owner); in TEST_F() 99 struct statfs statbuf; in TEST_F() local 136 struct statfs statbuf; in TEST_F() local 158 EXPECT_EQ(1024ul, statbuf.f_bsize); in TEST_F() 164 EXPECT_EQ(100ul, statbuf.f_bfree); in TEST_F() 165 EXPECT_EQ(200l, statbuf.f_bavail); in TEST_F() 166 EXPECT_EQ(5ul, statbuf.f_files); in TEST_F() 167 EXPECT_EQ(6l, statbuf.f_ffree); in TEST_F() [all …]
|
| H A D | mount.cc | 70 struct statfs statbuf; in TEST_P() local 95 ASSERT_EQ(0, statfs("mountpoint", &statbuf)) << strerror(errno); in TEST_P() 96 newflags = (statbuf.f_flags | MNT_UPDATE) ^ flag; in TEST_P() 99 build_iovec(&iov, &iovlen, "fspath", (void*)statbuf.f_mntonname, -1); in TEST_P() 103 ASSERT_EQ(0, statfs("mountpoint", &statbuf)) << strerror(errno); in TEST_P() 104 EXPECT_FALSE((newflags ^ statbuf.f_flags) & flag); in TEST_P() 110 struct statfs statbuf; in TEST_P() local 130 ASSERT_EQ(0, statfs("mountpoint", &statbuf)) << strerror(errno); in TEST_P() 131 newflags = (statbuf.f_flags | MNT_UPDATE) ^ flag; in TEST_P() 143 ASSERT_EQ(0, statfs("mountpoint", &statbuf)) << strerror(errno); in TEST_P() [all …]
|
| /freebsd-12.1/contrib/opie/libopie/ |
| H A D | lock.c | 95 struct stat statbuf[2]; variable 118 if (lstat(__opie_lockfilename, &statbuf[0]) < 0) 121 if (statbuf[0].st_uid) { 128 if (!S_ISDIR(statbuf[0].st_mode)) { 135 if ((statbuf[0].st_mode & 0777) != 00700) { 147 if (!lstat(__opie_lockfilename, &statbuf[0])) 148 if (!S_ISREG(statbuf[0].st_mode)) 154 if (statbuf[0].st_ino != statbuf[1].st_ino) 156 if (statbuf[0].st_mode != statbuf[1].st_mode) 200 if (fstat(fh, &statbuf[1]) < 0) [all …]
|
| /freebsd-12.1/sys/contrib/zstd/tests/ |
| H A D | roundTripCrash.c | 162 struct _stat64 statbuf; in getFileSize() local 163 r = _stat64(infilename, &statbuf); in getFileSize() 166 struct stat statbuf; in getFileSize() local 167 r = stat(infilename, &statbuf); in getFileSize() 170 return (size_t)statbuf.st_size; in getFileSize() 178 struct _stat64 statbuf; in isDirectory() local 179 r = _stat64(infilename, &statbuf); in isDirectory() 180 if (!r && (statbuf.st_mode & _S_IFDIR)) return 1; in isDirectory() 182 struct stat statbuf; in isDirectory() local 183 r = stat(infilename, &statbuf); in isDirectory() [all …]
|
| /freebsd-12.1/sys/contrib/zstd/programs/ |
| H A D | util.h | 275 res += chown(filename, statbuf->st_uid, statbuf->st_gid); /* Copy ownership */ in UTIL_setFileStat() 292 r = stat(infilename, statbuf); in UTIL_getFileStat() 301 stat_t statbuf; in UTIL_isRegularFile() local 309 stat_t statbuf; in UTIL_isDirectory() local 314 r = stat(infilename, &statbuf); in UTIL_isDirectory() 327 stat_t statbuf; in UTIL_isLink() 328 r = lstat(infilename, &statbuf); in UTIL_isLink() 341 struct __stat64 statbuf; in UTIL_getFileSize() local 345 struct _stati64 statbuf; in UTIL_getFileSize() local 349 struct stat statbuf; in UTIL_getFileSize() local [all …]
|
| /freebsd-12.1/contrib/binutils/binutils/ |
| H A D | rename.c | 99 set_times (const char *destination, const struct stat *statbuf) in set_times() argument 107 tb.actime = statbuf->st_atime; in set_times() 108 tb.modtime = statbuf->st_mtime; in set_times() 114 tb[0] = statbuf->st_atime; in set_times() 115 tb[1] = statbuf->st_mtime; in set_times() 120 tv[0].tv_sec = statbuf->st_atime; in set_times() 122 tv[1].tv_sec = statbuf->st_mtime; in set_times()
|
| H A D | bucomm.c | 511 struct stat statbuf; in get_file_size() local 513 if (stat (file_name, &statbuf) < 0) in get_file_size() 521 else if (! S_ISREG (statbuf.st_mode)) in get_file_size() 524 return statbuf.st_size; in get_file_size()
|
| /freebsd-12.1/usr.sbin/cron/cron/ |
| H A D | database.c | 46 struct stat statbuf; local 67 if (stat(SPOOL_DIR, &statbuf) < OK) { 77 maxmtime = TMAX(statbuf.st_mtime, syscron_stat.st_mtime); 176 &statbuf, &new_db, old_db); 251 process_crontab(uname, fname, tabname, statbuf, new_db, old_db) in process_crontab() argument 255 struct stat *statbuf; 279 if (fstat(crontab_fd, statbuf) < OK) { 290 if (u->mtime == statbuf->st_mtime) { 311 u->mtime = statbuf->st_mtime;
|
| /freebsd-12.1/tests/sys/cddl/zfs/tests/exec/ |
| H A D | mmap_exec.c | 43 struct stat statbuf; in main() local 58 if (fstat(fd, &statbuf) < 0) { in main() 63 if (mmap(0, statbuf.st_size, in main()
|
| /freebsd-12.1/cddl/contrib/opensolaris/lib/libzfs/common/ |
| H A D | libzfs_import.c | 877 struct stat64 statbuf; in zpool_read_label() local 884 if (fstat64(fd, &statbuf) == -1) in zpool_read_label() 933 struct stat64 statbuf; in zpool_read_all_labels() local 943 if (fstat64(fd, &statbuf) == -1) in zpool_read_all_labels() 1139 struct stat64 statbuf; in zpool_open_func() local 1157 !S_ISCHR(statbuf.st_mode) && in zpool_open_func() 1164 if (S_ISREG(statbuf.st_mode) && in zpool_open_func() 1198 struct stat64 statbuf; in zpool_clear_label() local 1203 if (fstat64(fd, &statbuf) == -1) in zpool_clear_label() 1463 struct stat64 statbuf; in zpool_find_import_cached() local [all …]
|
| /freebsd-12.1/cddl/contrib/opensolaris/cmd/zinject/ |
| H A D | translate.c | 88 struct stat64 *statbuf) in parse_pathname() argument 108 if (stat64(fullpath, statbuf) != 0) { in parse_pathname() 149 object_from_path(const char *dataset, const char *path, struct stat64 *statbuf, in object_from_path() argument 169 record->zi_object = statbuf->st_ino; in object_from_path() 320 struct stat64 statbuf; in translate_record() local 365 if (parse_pathname(object, dataset, path, &statbuf) != 0) in translate_record() 374 if (object_from_path(dataset, path, &statbuf, record) != 0) in translate_record()
|
| /freebsd-12.1/contrib/ncurses/ncurses/tinfo/ |
| H A D | write_entry.c | 166 struct stat statbuf; in make_db_root() 168 if ((rc = stat(path, &statbuf)) < 0) { in make_db_root() 176 } else if (!(S_ISDIR(statbuf.st_mode))) { in make_db_root() 260 struct stat statbuf; in _nc_write_entry() 381 stat(filename, &statbuf) >= 0 in _nc_write_entry() 382 && statbuf.st_mtime >= start_time) { in _nc_write_entry() 390 if (statbuf.st_nlink > 1) { in _nc_write_entry() 405 if (stat(filename, &statbuf) < 0 in _nc_write_entry() 406 || (start_time = statbuf.st_mtime) == 0) { in _nc_write_entry() 434 } else if (stat(linkname, &statbuf) >= 0 && in _nc_write_entry() [all …]
|
| /freebsd-12.1/contrib/compiler-rt/include/sanitizer/ |
| H A D | linux_syscall_hooks.h | 478 #define __sanitizer_syscall_pre_stat(filename, statbuf) \ argument 500 #define __sanitizer_syscall_pre_lstat(filename, statbuf) \ argument 504 #define __sanitizer_syscall_pre_fstat(fd, statbuf) \ argument 506 #define __sanitizer_syscall_post_fstat(res, fd, statbuf) \ argument 508 #define __sanitizer_syscall_pre_newstat(filename, statbuf) \ argument 516 #define __sanitizer_syscall_pre_newfstat(fd, statbuf) \ argument 524 #define __sanitizer_syscall_pre_stat64(filename, statbuf) \ argument 528 #define __sanitizer_syscall_pre_fstat64(fd, statbuf) \ argument 2294 long statbuf); 2304 long statbuf); [all …]
|
| /freebsd-12.1/cddl/contrib/opensolaris/cmd/zpool/ |
| H A D | zpool_vdev.c | 420 struct stat64 statbuf; in make_leaf_vdev() local 482 if (S_ISCHR(statbuf.st_mode)) { in make_leaf_vdev() 483 statbuf.st_mode &= ~S_IFCHR; in make_leaf_vdev() 484 statbuf.st_mode |= S_IFBLK; in make_leaf_vdev() 494 } else if (S_ISREG(statbuf.st_mode)) { in make_leaf_vdev() 659 struct stat64 statbuf; in get_replication() local 747 err = fstat64(fd, &statbuf); in get_replication() 750 err = stat64(path, &statbuf); in get_replication() 754 statbuf.st_size == 0 || in get_replication() 755 statbuf.st_size == MAXOFFSET_T) in get_replication() [all …]
|
| /freebsd-12.1/stand/ficl/ |
| H A D | fileaccess.c | 152 struct stat statbuf; in ficlFileStatus() local 161 if (stat(filename, &statbuf) == 0) in ficlFileStatus() 168 stackPushINT(pVM->pStack, statbuf.st_mode); in ficlFileStatus() 191 struct stat statbuf; in fileSize() local 192 statbuf.st_size = -1; in fileSize() 193 if (fstat(fileno(f), &statbuf) != 0) in fileSize() 195 return statbuf.st_size; in fileSize()
|
| /freebsd-12.1/contrib/less/ |
| H A D | filename.c | 990 struct stat statbuf; local 992 r = stat(filename, &statbuf); 993 isdir = (r >= 0 && S_ISDIR(statbuf.st_mode)); 1033 struct stat statbuf; local 1035 r = stat(filename, &statbuf); 1042 } else if (!S_ISREG(statbuf.st_mode)) 1064 struct stat statbuf; local 1066 if (fstat(f, &statbuf) >= 0) 1067 return ((POSITION) statbuf.st_size);
|
| /freebsd-12.1/usr.sbin/cron/crontab/ |
| H A D | crontab.c | 324 struct stat statbuf, fsbuf; local 374 if (stat(Filename, &statbuf) < 0) { 381 if (statbuf.st_dev != fsbuf.st_dev || statbuf.st_ino != fsbuf.st_ino) 448 if (stat(Filename, &statbuf) < 0) { 452 if (statbuf.st_dev != fsbuf.st_dev || statbuf.st_ino != fsbuf.st_ino)
|
| /freebsd-12.1/contrib/dtc/ |
| H A D | dtc.c | 140 struct stat statbuf; in guess_input_format() local 144 if (stat(fname, &statbuf) != 0) in guess_input_format() 147 if (S_ISDIR(statbuf.st_mode)) in guess_input_format() 150 if (!S_ISREG(statbuf.st_mode)) in guess_input_format()
|
| /freebsd-12.1/contrib/binutils/bfd/ |
| H A D | trad-core.c | 112 struct stat statbuf; local 114 if (bfd_stat (abfd, &statbuf) < 0) 122 > (ufile_ptr) statbuf.st_size) 134 < (ufile_ptr) statbuf.st_size)
|
| /freebsd-12.1/usr.sbin/ypserv/ |
| H A D | yp_access.c | 321 struct stat statbuf; local 331 if (stat(dompath, &statbuf) < 0 || !S_ISDIR(statbuf.st_mode))
|
| /freebsd-12.1/lib/libc/net/ |
| H A D | nsdispatch.c | 338 struct stat statbuf; in nss_configure() local 355 if (stat(path, &statbuf) != 0) in nss_configure() 357 if (statbuf.st_mtime <= confmod) in nss_configure() 364 if (stat(path, &statbuf) != 0) in nss_configure() 366 if (statbuf.st_mtime <= confmod) in nss_configure() 382 confmod = statbuf.st_mtime; in nss_configure()
|
| /freebsd-12.1/tools/regression/fsx/ |
| H A D | fsx.c | 426 struct stat statbuf; in check_size() local 429 if (fstat(fd, &statbuf)) { in check_size() 431 statbuf.st_size = -1; in check_size() 434 if (file_size != statbuf.st_size || file_size != size_by_seek) { in check_size() 437 (unsigned long long)statbuf.st_size, in check_size() 447 struct stat statbuf; in check_trunc_hack() local 451 fstat(fd, &statbuf); in check_trunc_hack() 452 if (statbuf.st_size != (off_t)100000) { in check_trunc_hack()
|
| /freebsd-12.1/contrib/compiler-rt/lib/sanitizer_common/ |
| H A D | sanitizer_common_syscalls.inc | 830 if (statbuf) POST_WRITE(statbuf, struct___old_kernel_stat_sz); 882 if (statbuf) POST_WRITE(statbuf, struct___old_kernel_stat_sz); 890 if (statbuf) POST_WRITE(statbuf, struct___old_kernel_stat_sz); 902 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat_sz); 914 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat_sz); 922 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat_sz); 944 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat64_sz); 952 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat64_sz); 964 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat64_sz); 2588 if (statbuf) POST_WRITE(statbuf, struct_kernel_stat_sz); [all …]
|
| /freebsd-12.1/contrib/mtree/ |
| H A D | verify.c | 186 struct stat statbuf; in miss() local 188 if (qflag && stat(path, &statbuf) == 0 && in miss() 189 S_ISDIR(statbuf.st_mode)) in miss()
|
| /freebsd-12.1/contrib/binutils/gas/ |
| H A D | hash.c | 443 int statbuf[STATBUFSIZE]; variable 545 hash_say (h, statbuf, STATBUFSIZE); in main() 546 for (ip = statbuf; ip < statbuf + STATBUFSIZE; ip++) in main()
|