Home
last modified time | relevance | path

Searched refs:tempname (Results 1 – 24 of 24) sorted by relevance

/freebsd-12.1/usr.bin/mail/
H A Dedit.c146 (void)snprintf(tempname, sizeof(tempname), in run_editor()
150 warn("%s", tempname); in run_editor()
154 warn("%s", tempname); in run_editor()
155 (void)rm(tempname); in run_editor()
172 (void)rm(tempname); in run_editor()
178 (void)rm(tempname); in run_editor()
186 (void)rm(tempname); in run_editor()
194 (void)rm(tempname); in run_editor()
202 (void)rm(tempname); in run_editor()
210 (void)rm(tempname); in run_editor()
[all …]
H A Dquit.c112 (void)snprintf(tempname, sizeof(tempname), in quit()
133 (void)rm(tempname); in quit()
204 (void)snprintf(tempname, sizeof(tempname), in quit()
208 warn("%s", tempname); in quit()
213 warn("%s", tempname); in quit()
214 (void)rm(tempname); in quit()
219 (void)rm(tempname); in quit()
428 (void)snprintf(tempname, sizeof(tempname), in edstop()
439 (void)rm(tempname); in edstop()
450 (void)rm(tempname); in edstop()
[all …]
H A Dcollect.c101 (void)rm(tempname); in collect()
107 (void)snprintf(tempname, sizeof(tempname), in collect()
109 if ((fd = mkstemp(tempname)) == -1 || in collect()
111 warn("%s", tempname); in collect()
114 (void)rm(tempname); in collect()
430 if (forward(linebuf + 2, collf, tempname, c) < 0) in collect()
567 char *sh, tempname[PATHSIZE]; in mespipe() local
569 (void)snprintf(tempname, sizeof(tempname), in mespipe()
571 if ((fd = mkstemp(tempname)) == -1 || in mespipe()
573 warn("%s", tempname); in mespipe()
[all …]
H A Dsend.c460 char tempname[PATHSIZE]; in infix() local
462 (void)snprintf(tempname, sizeof(tempname), in infix()
464 if ((fd = mkstemp(tempname)) == -1 || in infix()
466 warn("%s", tempname); in infix()
469 if ((nfi = Fopen(tempname, "r")) == NULL) { in infix()
470 warn("%s", tempname); in infix()
472 (void)rm(tempname); in infix()
475 (void)rm(tempname); in infix()
490 warn("%s", tempname); in infix()
H A Dlex.c74 char tempname[PATHSIZE]; in setfile() local
132 (void)snprintf(tempname, sizeof(tempname), in setfile()
134 if ((fd = mkstemp(tempname)) == -1 || (otf = fdopen(fd, "w")) == NULL) in setfile()
135 err(1, "%s", tempname); in setfile()
137 if ((itf = fopen(tempname, "r")) == NULL) in setfile()
138 err(1, "%s", tempname); in setfile()
140 (void)rm(tempname); in setfile()
H A Dnames.c313 char tempname[PATHSIZE]; in outof() local
315 (void)snprintf(tempname, sizeof(tempname), in outof()
317 if ((fd = mkstemp(tempname)) == -1 || in outof()
319 warn("%s", tempname); in outof()
323 image = open(tempname, O_RDWR); in outof()
324 (void)rm(tempname); in outof()
326 warn("%s", tempname); in outof()
341 warn("%s", tempname); in outof()
/freebsd-12.1/sbin/ldconfig/
H A Delfhints.c257 char *tempname; in write_elf_hints() local
264 if ((fd = mkstemp(tempname)) == -1) in write_elf_hints()
265 err(1, "mkstemp(%s)", tempname); in write_elf_hints()
267 err(1, "fchmod(%s)", tempname); in write_elf_hints()
269 err(1, "fdopen(%s)", tempname); in write_elf_hints()
289 err(1, "%s: write error", tempname); in write_elf_hints()
293 err(1, "%s: write error", tempname); in write_elf_hints()
296 err(1, "%s: write error", tempname); in write_elf_hints()
299 err(1, "%s: write error", tempname); in write_elf_hints()
301 if (rename(tempname, hintsfile) == -1) in write_elf_hints()
[all …]
/freebsd-12.1/lib/libutil/
H A Dpw_util.c73 static char tempname[PATH_MAX]; variable
221 if (snprintf(tempname, sizeof(tempname), "%.*spw.XXXXXX", in pw_tmp()
233 unlink(tempname); in pw_tmp()
234 *tempname = '\0'; in pw_tmp()
293 if (stat(tempname, &st1) == -1) in pw_edit()
325 unlink(tempname); in pw_edit()
334 unlink(tempname); in pw_edit()
366 if (*tempname != '\0') { in pw_fini()
367 unlink(tempname); in pw_fini()
368 *tempname = '\0'; in pw_fini()
[all …]
H A Dgr_util.c52 static char tempname[PATH_MAX]; variable
141 if (snprintf(tempname, sizeof(tempname), "%.*sgroup.XXXXXX", in gr_tmp()
142 (int)(p - group_file), group_file) >= (int)sizeof(tempname)) { in gr_tmp()
146 if ((tfd = mkostemp(tempname, 0)) == -1) in gr_tmp()
153 unlink(tempname); in gr_tmp()
154 *tempname = '\0'; in gr_tmp()
336 if (chmod(tempname, 0644) != 0) in gr_mkdb()
339 if (rename(tempname, group_file) != 0) in gr_mkdb()
370 if (*tempname != '\0') { in gr_fini()
371 unlink(tempname); in gr_fini()
[all …]
/freebsd-12.1/release/picobsd/tinyware/passwd/
H A Dpw_util.c68 extern char *tempname;
167 tempname = path; in pw_tmp()
182 tempname, (char *)NULL); in pw_mkdb()
186 "-u", username, tempname, (char *)NULL); in pw_mkdb()
216 execlp(editor, p, tempname, (char *)NULL); in pw_edit()
258 (void)unlink(tempname); in pw_error()
H A Dpw_copy.c62 extern char *tempname;
104 pw_error(tempname, 1, 1); in pw_copy()
H A Dlocal_passwd.c80 char *tempname; variable
/freebsd-12.1/contrib/less/
H A Dcmdbuf.c1538 char *tempname = ecalloc(1, strlen(filename)+1); local
1539 strcpy(tempname, filename);
1540 lastch = tempname[strlen(tempname)-1];
1541 tempname[strlen(tempname)-1] = (lastch == 'Q') ? 'Z' : 'Q';
1542 return tempname;
1638 char *tempname; in save_cmdhist() local
1651 tempname = make_tempname(histname); in save_cmdhist()
1652 fout = fopen(tempname, "w"); in save_cmdhist()
1677 rename(tempname, histname); in save_cmdhist()
1679 free(tempname); in save_cmdhist()
/freebsd-12.1/lib/libc/tests/gen/
H A Ddlopen_empty_test.c60 char tempname[] = "/tmp/temp.XXXXXX"; in ATF_TC_BODY() local
66 fname = mktemp(tempname); in ATF_TC_BODY()
/freebsd-12.1/usr.bin/unifdef/
H A Dunifdef.c412 tempname = astrcat(ofn, ".XXXXXX"); in processinout()
413 output = mktempmode(tempname, st.st_mode); in processinout()
415 err(2, "can't create %s", tempname); in processinout()
427 if (remove(tempname) < 0) in processinout()
428 warn("can't remove \"%s\"", tempname); in processinout()
429 } else if (replace(tempname, ofn) < 0) in processinout()
430 err(2, "can't rename \"%s\" to \"%s\"", tempname, ofn); in processinout()
431 free(tempname); in processinout()
432 tempname = NULL; in processinout()
441 if (tempname != NULL) in cleantemp()
[all …]
/freebsd-12.1/usr.sbin/kldxref/
H A Dkldxref.c620 static char xrefname[MAXPATHLEN], tempname[MAXPATHLEN]; variable
695 rename(tempname, xrefname); in main()
698 unlink(tempname); in main()
708 fxref = maketempfile(tempname, ftsp->fts_path); in main()
710 err(1, "can't create %s", tempname); in main()
/freebsd-12.1/release/picobsd/tinyware/msh/
H A Dsh5.c25 _PROTOTYPE(void tempname, (char *tname ));
552 tempname(tname);
610 tempname(tname);
664 tempname(tname) in tempname() function
/freebsd-12.1/contrib/diff/
H A DFREEBSD-Xlist46 lib/tempname.c
H A DChangeLog680 (tempname): Use AC_LIBOBJS, not LIBOBJS=, as now required by autoconf.
708 lib/tempname.c: Update to latest version from other packages.
1677 * lib/tempname.c (uint64_t):
1682 * lib/tempname.c: glibc 1.32
1690 * lib/tempname.c (struct_stat64): New macro.
1694 * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
/freebsd-12.1/sbin/fsck_ffs/
H A Ddir.c467 char tempname[BUFSIZ]; in linkup() local
544 (void)lftempname(tempname, orphan); in linkup()
545 if (makeentry(lfdir, orphan, (name ? name : tempname)) == 0) { in linkup()
/freebsd-12.1/contrib/gcc/
H A Dtree-ssa-structalias.c3917 char *tempname; in create_function_info_for() local
3926 newname = ggc_strdup (tempname); in create_function_info_for()
3927 free (tempname); in create_function_info_for()
3951 char *tempname; in create_function_info_for() local
3961 asprintf (&tempname, "%s.result", name); in create_function_info_for()
3962 newname = ggc_strdup (tempname); in create_function_info_for()
3963 free (tempname); in create_function_info_for()
4189 char *tempname; in create_variable_info_for() local
4195 asprintf (&tempname, "%s.%s", in create_variable_info_for()
4200 newname = ggc_strdup (tempname); in create_variable_info_for()
[all …]
/freebsd-12.1/crypto/openssl/apps/
H A Dapps.c2342 WCHAR tempname[MAX_PATH]; in app_isdir() local
2348 if (!MultiByteToWideChar(CP_ACP, 0, name, len_0, tempname, MAX_PATH)) in app_isdir()
2351 tempname[i] = (WCHAR)name[i]; in app_isdir()
2353 attr = GetFileAttributes(tempname); in app_isdir()
/freebsd-12.1/contrib/subversion/subversion/libsvn_subr/
H A Dio.c5266 const char *tempname; in svn_io_open_unique_file3() local
5313 SVN_ERR(temp_file_create(&tempfile, &tempname, dirpath, flags, in svn_io_open_unique_file3()
5342 svn_dirent_local_style(tempname, scratch_pool)); in svn_io_open_unique_file3()
5354 *unique_path = tempname; /* Was allocated in result_pool */ in svn_io_open_unique_file3()
5357 SVN_ERR(cstring_from_utf8(&baton->fname_apr, tempname, result_pool)); in svn_io_open_unique_file3()
/freebsd-12.1/contrib/binutils/binutils/
H A DChangeLog250 (copy_main): Refactor tempname detection and use.