Symbol: tempfile
bin/pax/extern.h
234
extern char *tempfile;
bin/pax/pax.c
240
tempfile = malloc(tdlen + 1 + sizeof(_TFILE_BASE));
bin/pax/pax.c
241
if (tempfile == NULL) {
bin/pax/pax.c
246
memcpy(tempfile, tmpdir, tdlen);
bin/pax/pax.c
247
tempbase = tempfile + tdlen;
bin/pax/pax.c
92
char *tempfile; /* tempfile to use for mkstemp(3) */
bin/pax/tables.c
1095
if ((dirfd = mkstemp(tempfile)) >= 0) {
bin/pax/tables.c
1096
(void)unlink(tempfile);
bin/pax/tables.c
1100
tempfile);
bin/pax/tables.c
339
if ((ffd = mkstemp(tempfile)) < 0) {
bin/pax/tables.c
341
tempfile);
bin/pax/tables.c
344
(void)unlink(tempfile);
tests/sys/kern/unix_passfd_test.c
1048
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
347
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
369
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
393
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
417
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
438
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
456
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
561
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
584
tempfile(&putfd);
tests/sys/kern/unix_passfd_test.c
632
tempfile(&putfd_1);
tests/sys/kern/unix_passfd_test.c
633
tempfile(&putfd_2);
tests/sys/kern/unix_passfd_test.c
720
tempfile(&putfd);
usr.bin/diff/diffreg.c
522
char buf[BUFSIZ], tempfile[PATH_MAX];
usr.bin/diff/diffreg.c
531
(void)strlcpy(tempfile, _PATH_TMP "/diff.XXXXXXXX", sizeof(tempfile));
usr.bin/diff/diffreg.c
533
if ((ofd = mkstemp(tempfile)) == -1) {
usr.bin/diff/diffreg.c
537
unlink(tempfile);
usr.bin/xinstall/xinstall.c
808
char backup[MAXPATHLEN], *p, pathbuf[MAXPATHLEN], tempfile[MAXPATHLEN];
usr.bin/xinstall/xinstall.c
869
to_fd = create_tempfile(to_name, tempfile,
usr.bin/xinstall/xinstall.c
870
sizeof(tempfile));
usr.bin/xinstall/xinstall.c
872
err(EX_OSERR, "%s", dirname(tempfile));
usr.bin/xinstall/xinstall.c
875
stripped = strip(tempfile, to_fd, from_name,
usr.bin/xinstall/xinstall.c
880
tempfile);
usr.bin/xinstall/xinstall.c
887
(void)strip(tempfile, to_fd, NULL, &digestresult);
usr.bin/xinstall/xinstall.c
894
to_fd = open(tempfile, O_RDONLY, 0);
usr.bin/xinstall/xinstall.c
911
(void)unlink(tempfile);
usr.bin/xinstall/xinstall.c
913
err(EX_OSERR, "%s", tempfile);
usr.bin/xinstall/xinstall.c
916
if (compare(temp_fd, tempfile, (size_t)temp_sb.st_size, to_fd,
usr.bin/xinstall/xinstall.c
927
(void)utimensat(AT_FDCWD, tempfile, tsb, 0);
usr.bin/xinstall/xinstall.c
930
(void)unlink(tempfile);
usr.bin/xinstall/xinstall.c
935
digestresult = digest_file(tempfile);
usr.bin/xinstall/xinstall.c
950
unlink(tempfile);
usr.bin/xinstall/xinstall.c
962
unlink(tempfile);
usr.bin/xinstall/xinstall.c
968
unlink(tempfile);
usr.bin/xinstall/xinstall.c
980
if (rename(tempfile, to_name) < 0) {
usr.bin/xinstall/xinstall.c
982
unlink(tempfile);
usr.bin/xinstall/xinstall.c
985
tempfile, to_name);
usr.sbin/newsyslog/newsyslog.c
2748
char *realfile, *slash, tempfile[MAXPATHLEN];
usr.sbin/newsyslog/newsyslog.c
2759
strlcpy(tempfile, realfile, sizeof(tempfile));
usr.sbin/newsyslog/newsyslog.c
2760
slash = strrchr(tempfile, '/');
usr.sbin/newsyslog/newsyslog.c
2763
failed = stat(tempfile, &st);
usr.sbin/newsyslog/newsyslog.c
2765
err(1, "Error on stat(%s)", tempfile);
usr.sbin/newsyslog/newsyslog.c
2767
createdir(ent, tempfile);
usr.sbin/newsyslog/newsyslog.c
2770
tempfile);
usr.sbin/newsyslog/newsyslog.c
2780
strlcpy(tempfile, realfile, sizeof(tempfile));
usr.sbin/newsyslog/newsyslog.c
2781
strlcat(tempfile, ".zXXXXXX", sizeof(tempfile));
usr.sbin/newsyslog/newsyslog.c
2783
printf("\tmktemp %s\n", tempfile);
usr.sbin/newsyslog/newsyslog.c
2785
fd = mkstemp(tempfile);
usr.sbin/newsyslog/newsyslog.c
2787
err(1, "can't mkstemp logfile %s", tempfile);
usr.sbin/newsyslog/newsyslog.c
2793
if (log_trim(tempfile, ent))
usr.sbin/newsyslog/newsyslog.c
2802
tempfile);
usr.sbin/newsyslog/newsyslog.c
2806
err(1, "can't fchown temp file %s", tempfile);
usr.sbin/newsyslog/newsyslog.c
2813
printf("\tchflags nodump %s\n", tempfile);
usr.sbin/newsyslog/newsyslog.c
2833
printf("\tchmod %o %s\n", ent->permissions, tempfile);
usr.sbin/newsyslog/newsyslog.c
2834
printf("\tmv %s %s\n", tempfile, realfile);
usr.sbin/newsyslog/newsyslog.c
2838
err(1, "can't fchmod temp file '%s'", tempfile);
usr.sbin/newsyslog/newsyslog.c
2839
failed = rename(tempfile, realfile);
usr.sbin/newsyslog/newsyslog.c
2841
err(1, "can't mv %s to %s", tempfile, realfile);