Home
last modified time | relevance | path

Searched refs:statbuf (Results 1 – 25 of 171) sorted by relevance

1234567

/netbsd-src/external/gpl2/gettext/dist/gettext-tools/gnulib-lib/
H A Dcopy-file.c52 struct stat statbuf; in copy_file_preserving() local
59 if (src_fd < 0 || fstat (src_fd, &statbuf) < 0) in copy_file_preserving()
63 mode = statbuf.st_mode & 07777; in copy_file_preserving()
93 ut.actime = statbuf.st_atime; in copy_file_preserving()
94 ut.modtime = statbuf.st_mtime; in copy_file_preserving()
101 ut[0].tv_sec = statbuf.st_atime; ut[0].tv_usec = 0; in copy_file_preserving()
102 ut[1].tv_sec = statbuf.st_mtime; ut[1].tv_usec = 0; in copy_file_preserving()
109 chown (dest_filename, statbuf.st_uid, statbuf.st_gid); in copy_file_preserving()
H A Djavacomp.c605 struct stat statbuf; in is_envjavac_gcj_14_14_usable() local
628 && stat (compiled_file_name, &statbuf) >= 0) in is_envjavac_gcj_14_14_usable()
663 struct stat statbuf; in is_envjavac_gcj_14_13_usable() local
690 && stat (compiled_file_name, &statbuf) >= 0) in is_envjavac_gcj_14_13_usable()
704 && stat (compiled_file_name, &statbuf) >= 0) in is_envjavac_gcj_14_13_usable()
736 && stat (compiled_file_name, &statbuf) >= 0) in is_envjavac_gcj_14_13_usable()
745 && stat (compiled_file_name, &statbuf) >= 0)) in is_envjavac_gcj_14_13_usable()
806 struct stat statbuf; in is_envjavac_nongcj_usable() local
830 && stat (compiled_file_name, &statbuf) >= 0 in is_envjavac_nongcj_usable()
845 && stat (compiled_file_name, &statbuf) >= 0 in is_envjavac_nongcj_usable()
[all …]
/netbsd-src/external/gpl3/binutils/dist/binutils/
H A Drename.c169 set_times (const char *destination, const struct stat *statbuf) in set_times() argument
174 times[0] = get_stat_atime (statbuf); in set_times()
175 times[1] = get_stat_mtime (statbuf); in set_times()
180 tv[0].tv_sec = statbuf->st_atime; in set_times()
181 tv[0].tv_usec = get_stat_atime_ns (statbuf) / 1000; in set_times()
182 tv[1].tv_sec = statbuf->st_mtime; in set_times()
183 tv[1].tv_usec = get_stat_mtime_ns (statbuf) / 1000; in set_times()
188 tb.actime = statbuf->st_atime; in set_times()
189 tb.modtime = statbuf->st_mtime; in set_times()
194 tb[0] = statbuf->st_atime; in set_times()
[all …]
H A Dbucomm.c618 struct stat statbuf; in get_file_size() local
623 if (stat (file_name, &statbuf) < 0) in get_file_size()
631 else if (S_ISDIR (statbuf.st_mode)) in get_file_size()
633 else if (! S_ISREG (statbuf.st_mode)) in get_file_size()
635 if (!S_ISCHR(statbuf.st_mode)) in get_file_size()
640 return statbuf.st_size ? statbuf.st_size : 1; in get_file_size()
642 else if (statbuf.st_size < 0) in get_file_size()
646 else if (statbuf.st_size == 0) in get_file_size()
661 return statbuf.st_size; in get_file_size()
/netbsd-src/sbin/mount_umap/
H A Dmount_umap.c103 struct stat statbuf; in mount_umap() local
156 if (fstat(fileno(fp), &statbuf)) in mount_umap()
158 if (statbuf.st_mode & S_IWGRP || statbuf.st_mode & S_IWOTH) { in mount_umap()
159 strmode(statbuf.st_mode, buf); in mount_umap()
163 if (statbuf.st_uid != ROOTUSER) in mount_umap()
204 if (fstat(fileno(gfp), &statbuf)) in mount_umap()
206 if (statbuf.st_mode & S_IWGRP || statbuf.st_mode & S_IWOTH) { in mount_umap()
207 strmode(statbuf.st_mode, buf); in mount_umap()
211 if (statbuf.st_uid != ROOTUSER) in mount_umap()
/netbsd-src/external/gpl3/binutils.old/dist/binutils/
H A Drename.c169 set_times (const char *destination, const struct stat *statbuf) in set_times() argument
174 times[0] = get_stat_atime (statbuf); in set_times()
175 times[1] = get_stat_mtime (statbuf); in set_times()
180 tv[0].tv_sec = statbuf->st_atime; in set_times()
181 tv[0].tv_usec = get_stat_atime_ns (statbuf) / 1000; in set_times()
182 tv[1].tv_sec = statbuf->st_mtime; in set_times()
183 tv[1].tv_usec = get_stat_mtime_ns (statbuf) / 1000; in set_times()
188 tb.actime = statbuf->st_atime; in set_times()
189 tb.modtime = statbuf->st_mtime; in set_times()
194 tb[0] = statbuf->st_atime; in set_times()
[all …]
H A Dbucomm.c616 struct stat statbuf; in get_file_size() local
621 if (stat (file_name, &statbuf) < 0) in get_file_size()
629 else if (S_ISDIR (statbuf.st_mode)) in get_file_size()
631 else if (! S_ISREG (statbuf.st_mode)) in get_file_size()
633 if (!S_ISCHR(statbuf.st_mode)) in get_file_size()
638 return statbuf.st_size ? statbuf.st_size : 1; in get_file_size()
640 else if (statbuf.st_size < 0) in get_file_size()
644 else if (statbuf.st_size == 0) in get_file_size()
659 return statbuf.st_size; in get_file_size()
/netbsd-src/external/gpl2/mkhybrid/dist/
H A Dtree.c1053 struct stat statbuf, lstatbuf; local
1063 status = stat_filter(whole_path, &statbuf);
1078 root_statbuf = statbuf; /* Save this for later on */
1083 statbuf = root_statbuf;
1101 statbuf.st_size = 0;
1102 STAT_INODE(statbuf) = UNCACHED_INODE;
1103 statbuf.st_dev = (dev_t) UNCACHED_DEVICE;
1104 statbuf.st_mode = (statbuf.st_mode & ~S_IFMT) | S_IFREG;
1131 && S_ISDIR(statbuf.st_mode) )
1136 if(find_directory_hash(statbuf.st_dev, STAT_INODE(statbuf)))
[all …]
/netbsd-src/external/gpl3/binutils.old/dist/bfd/
H A Daix5ppc-core.c57 struct stat statbuf; in xcoff64_core_p() local
73 if (bfd_stat (abfd, &statbuf) < 0) in xcoff64_core_p()
92 || ((CHECK_FILE_OFFSET (statbuf, core.c_fdsinfox))) in xcoff64_core_p()
93 || ((CHECK_FILE_OFFSET (statbuf, core.c_loader))) in xcoff64_core_p()
94 || ((CHECK_FILE_OFFSET (statbuf, core.c_loader + core.c_lsize))) in xcoff64_core_p()
95 || ((CHECK_FILE_OFFSET (statbuf, core.c_thr))) in xcoff64_core_p()
96 || ((CHECK_FILE_OFFSET (statbuf, core.c_segregion))) in xcoff64_core_p()
97 || ((CHECK_FILE_OFFSET (statbuf, core.c_stack))) in xcoff64_core_p()
98 || ((CHECK_FILE_OFFSET (statbuf, core.c_stack + core.c_size))) in xcoff64_core_p()
99 || ((CHECK_FILE_OFFSET (statbuf, core.c_data))) in xcoff64_core_p()
[all …]
/netbsd-src/external/mit/libuv/dist/src/
H A Dfs-poll.c46 uv_stat_t statbuf; member
186 uv_stat_t* statbuf; in poll_cb() local
201 &ctx->statbuf, in poll_cb()
208 statbuf = &req->statbuf; in poll_cb()
211 if (ctx->busy_polling < 0 || !statbuf_eq(&ctx->statbuf, statbuf)) in poll_cb()
212 ctx->poll_cb(ctx->parent_handle, 0, &ctx->statbuf, statbuf); in poll_cb()
214 ctx->statbuf = *statbuf; in poll_cb()
/netbsd-src/external/gpl3/binutils/dist/bfd/
H A Daix5ppc-core.c57 struct stat statbuf; in xcoff64_core_p() local
73 if (bfd_stat (abfd, &statbuf) < 0) in xcoff64_core_p()
92 || ((CHECK_FILE_OFFSET (statbuf, core.c_fdsinfox))) in xcoff64_core_p()
93 || ((CHECK_FILE_OFFSET (statbuf, core.c_loader))) in xcoff64_core_p()
94 || ((CHECK_FILE_OFFSET (statbuf, core.c_loader + core.c_lsize))) in xcoff64_core_p()
95 || ((CHECK_FILE_OFFSET (statbuf, core.c_thr))) in xcoff64_core_p()
96 || ((CHECK_FILE_OFFSET (statbuf, core.c_segregion))) in xcoff64_core_p()
97 || ((CHECK_FILE_OFFSET (statbuf, core.c_stack))) in xcoff64_core_p()
98 || ((CHECK_FILE_OFFSET (statbuf, core.c_stack + core.c_size))) in xcoff64_core_p()
99 || ((CHECK_FILE_OFFSET (statbuf, core.c_data))) in xcoff64_core_p()
[all …]
/netbsd-src/external/gpl3/gdb/dist/gnulib/import/
H A Dopen.c161 struct stat statbuf; in open() local
162 if (stat (filename, &statbuf) == 0 && S_ISDIR (statbuf.st_mode)) in open()
191 struct stat statbuf; in open() local
193 if (fstat (fd, &statbuf) >= 0 && !S_ISDIR (statbuf.st_mode)) in open()
/netbsd-src/external/gpl3/gcc/dist/libgfortran/io/
H A Dunix.c410 struct stat statbuf; in raw_size() local
411 if (TEMP_FAILURE_RETRY (fstat (s->fd, &statbuf)) == -1) in raw_size()
413 if (S_ISREG (statbuf.st_mode)) in raw_size()
414 return statbuf.st_size; in raw_size()
1116 struct stat statbuf; in fd_to_stream() local
1125 if (TEMP_FAILURE_RETRY (fstat (fd, &statbuf)) == -1) in fd_to_stream()
1135 s->st_dev = statbuf.st_dev; in fd_to_stream()
1136 s->st_ino = statbuf.st_ino; in fd_to_stream()
1137 s->file_length = statbuf.st_size; in fd_to_stream()
1140 if (S_ISREG (statbuf.st_mode) in fd_to_stream()
[all …]
/netbsd-src/external/gpl3/gcc.old/dist/libgfortran/io/
H A Dunix.c410 struct stat statbuf; in raw_size() local
411 if (TEMP_FAILURE_RETRY (fstat (s->fd, &statbuf)) == -1) in raw_size()
413 if (S_ISREG (statbuf.st_mode)) in raw_size()
414 return statbuf.st_size; in raw_size()
1116 struct stat statbuf; in fd_to_stream() local
1125 if (TEMP_FAILURE_RETRY (fstat (fd, &statbuf)) == -1) in fd_to_stream()
1135 s->st_dev = statbuf.st_dev; in fd_to_stream()
1136 s->st_ino = statbuf.st_ino; in fd_to_stream()
1137 s->file_length = statbuf.st_size; in fd_to_stream()
1140 if (S_ISREG (statbuf.st_mode) in fd_to_stream()
[all …]
/netbsd-src/external/bsd/cron/dist/
H A Ddatabase.c250 struct stat *statbuf, cron_db *new_db, cron_db *old_db) in process_crontab() argument
279 if (fstat(crontab_fd, statbuf) < OK) { in process_crontab()
283 if (!S_ISREG(statbuf->st_mode)) { in process_crontab()
287 if ((eqmode && (statbuf->st_mode & 07577) != eqmode) || in process_crontab()
288 (badmode && (statbuf->st_mode & badmode) != 0)) { in process_crontab()
292 if (statbuf->st_uid != ROOT_UID && (pw == NULL || in process_crontab()
293 statbuf->st_uid != pw->pw_uid || strcmp(uname, pw->pw_name) != 0)) { in process_crontab()
297 if (statbuf->st_nlink != 1) { in process_crontab()
308 if (u->mtime == statbuf->st_mtime) { in process_crontab()
329 u->mtime = statbuf->st_mtime; in process_crontab()
/netbsd-src/usr.bin/tail/
H A Dforward.c92 struct stat statbuf; in forward() local
244 stat(fname, &statbuf) != -1) { in forward()
245 if (statbuf.st_ino != sbp->st_ino || in forward()
246 statbuf.st_dev != sbp->st_dev || in forward()
247 statbuf.st_rdev != sbp->st_rdev || in forward()
248 statbuf.st_nlink == 0) { in forward()
254 *sbp = statbuf; in forward()
/netbsd-src/tests/fs/lfs/
H A Dt_rfw.c239 struct stat statbuf; in write_file() local
243 if (rump_sys_stat(filename, &statbuf) < 0) in write_file()
246 size = statbuf.st_size; in write_file()
265 struct stat statbuf; in check_file() local
268 if (rump_sys_stat(filename, &statbuf) < 0) { in check_file()
272 if (size != statbuf.st_size) { in check_file()
274 filename, size, (int)statbuf.st_size); in check_file()
/netbsd-src/external/gpl2/xcvs/dist/src/
H A Derror.c116 char statbuf[256]; in error() local
130 buf = statbuf; in error()
135 length = sizeof (statbuf); in error()
137 buf = vasnprintf (statbuf, &length, message, args); in error()
188 if (buf != statbuf) free (buf); in error()
/netbsd-src/external/gpl3/gcc/dist/libcody/
H A Dresolver.cc177 struct stat statbuf; in IncludeTranslateRequest() local
182 && fstatat (fd_dir, cmi.c_str (), &statbuf, 0) == 0 in IncludeTranslateRequest()
183 && S_ISREG (statbuf.st_mode)) in IncludeTranslateRequest()
193 if (stat (append.c_str (), &statbuf) == 0 in IncludeTranslateRequest()
194 || S_ISREG (statbuf.st_mode)) in IncludeTranslateRequest()
/netbsd-src/external/cddl/osnet/dist/cmd/zinject/
H A Dtranslate.c88 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()
/netbsd-src/external/cddl/osnet/dist/lib/libzfs/common/
H A Dlibzfs_import.c877 struct stat64 statbuf; in zpool_read_label() local
884 if (fstat64(fd, &statbuf) == -1) in zpool_read_label()
886 size = P2ALIGN_TYPED(statbuf.st_size, sizeof (vdev_label_t), uint64_t); in zpool_read_label()
1054 struct stat64 statbuf; in zpool_open_func() local
1070 if (fstat64(fd, &statbuf) != 0 || in zpool_open_func()
1071 (!S_ISREG(statbuf.st_mode) && in zpool_open_func()
1072 !S_ISCHR(statbuf.st_mode) && in zpool_open_func()
1073 !S_ISBLK(statbuf.st_mode))) { in zpool_open_func()
1079 if (S_ISREG(statbuf.st_mode) && in zpool_open_func()
1080 statbuf.st_size < SPA_MINDEVSIZE) { in zpool_open_func()
[all …]
/netbsd-src/external/gpl3/gcc.old/dist/libsanitizer/include/sanitizer/
H A Dlinux_syscall_hooks.h476 #define __sanitizer_syscall_pre_stat(filename, statbuf) \ argument
477 __sanitizer_syscall_pre_impl_stat((long)(filename), (long)(statbuf))
478 #define __sanitizer_syscall_post_stat(res, filename, statbuf) \ argument
479 __sanitizer_syscall_post_impl_stat(res, (long)(filename), (long)(statbuf))
498 #define __sanitizer_syscall_pre_lstat(filename, statbuf) \ argument
499 __sanitizer_syscall_pre_impl_lstat((long)(filename), (long)(statbuf))
500 #define __sanitizer_syscall_post_lstat(res, filename, statbuf) \ argument
501 __sanitizer_syscall_post_impl_lstat(res, (long)(filename), (long)(statbuf))
502 #define __sanitizer_syscall_pre_fstat(fd, statbuf) \ argument
503 __sanitizer_syscall_pre_impl_fstat((long)(fd), (long)(statbuf))
[all …]
/netbsd-src/sys/external/bsd/compiler_rt/dist/include/sanitizer/
H A Dlinux_syscall_hooks.h478 #define __sanitizer_syscall_pre_stat(filename, statbuf) \ argument
479 __sanitizer_syscall_pre_impl_stat((long)(filename), (long)(statbuf))
480 #define __sanitizer_syscall_post_stat(res, filename, statbuf) \ argument
481 __sanitizer_syscall_post_impl_stat(res, (long)(filename), (long)(statbuf))
500 #define __sanitizer_syscall_pre_lstat(filename, statbuf) \ argument
501 __sanitizer_syscall_pre_impl_lstat((long)(filename), (long)(statbuf))
502 #define __sanitizer_syscall_post_lstat(res, filename, statbuf) \ argument
503 __sanitizer_syscall_post_impl_lstat(res, (long)(filename), (long)(statbuf))
504 #define __sanitizer_syscall_pre_fstat(fd, statbuf) \ argument
505 __sanitizer_syscall_pre_impl_fstat((long)(fd), (long)(statbuf))
[all …]
/netbsd-src/external/gpl3/gcc/dist/libsanitizer/include/sanitizer/
H A Dlinux_syscall_hooks.h477 #define __sanitizer_syscall_pre_stat(filename, statbuf) \ argument
478 __sanitizer_syscall_pre_impl_stat((long)(filename), (long)(statbuf))
479 #define __sanitizer_syscall_post_stat(res, filename, statbuf) \ argument
480 __sanitizer_syscall_post_impl_stat(res, (long)(filename), (long)(statbuf))
499 #define __sanitizer_syscall_pre_lstat(filename, statbuf) \ argument
500 __sanitizer_syscall_pre_impl_lstat((long)(filename), (long)(statbuf))
501 #define __sanitizer_syscall_post_lstat(res, filename, statbuf) \ argument
502 __sanitizer_syscall_post_impl_lstat(res, (long)(filename), (long)(statbuf))
503 #define __sanitizer_syscall_pre_fstat(fd, statbuf) \ argument
504 __sanitizer_syscall_pre_impl_fstat((long)(fd), (long)(statbuf))
[all …]
/netbsd-src/external/cddl/osnet/dist/cmd/zpool/
H A Dzpool_vdev.c438 struct stat64 statbuf; in make_leaf_vdev() local
454 if (!wholedisk && (stat64(arg, &statbuf) != 0)) { in make_leaf_vdev()
474 if (!wholedisk && (stat64(path, &statbuf) != 0)) { in make_leaf_vdev()
500 if (S_ISCHR(statbuf.st_mode)) { in make_leaf_vdev()
501 statbuf.st_mode &= ~S_IFCHR; in make_leaf_vdev()
502 statbuf.st_mode |= S_IFBLK; in make_leaf_vdev()
510 if (wholedisk || S_ISBLK(statbuf.st_mode)) { in make_leaf_vdev()
512 } else if (S_ISREG(statbuf.st_mode)) { in make_leaf_vdev()
537 if (S_ISBLK(statbuf.st_mode) && !wholedisk) { in make_leaf_vdev()
677 struct stat64 statbuf; in get_replication() local
[all …]

1234567