Searched refs:pathbuf (Results 1 - 25 of 36) sorted by relevance

12

/freebsd-13-stable/contrib/openpam/lib/libpam/
H A Dopenpam_check_owner_perms.c104 char pathbuf[PATH_MAX]; local
111 if (realpath(path, pathbuf) == NULL)
113 len = strlen(pathbuf);
115 if (stat(pathbuf, &sb) != 0) {
118 openpam_log(PAM_LOG_ERROR, "%s: %m", pathbuf);
125 "%s: not a regular file", pathbuf);
132 "%s: insecure ownership or permissions", pathbuf);
136 while (--len > 0 && pathbuf[len] != '/')
137 pathbuf[len] = '\0';
/freebsd-13-stable/sbin/kldconfig/
H A Dkldconfig.c146 char pathbuf[MAXPATHLEN+1]; local
155 if (realpath(path, pathbuf) == NULL)
156 strlcpy(pathbuf, path, sizeof(pathbuf));
158 len = strlen(pathbuf);
160 if ((len > 0) && (pathbuf[len-1] == '/'))
161 pathbuf[--len] = '\0';
165 if (!strcmp(pe->path, pathbuf))
170 errx(1, "already in the module search path: %s", pathbuf);
175 ((pe->path = strdup(pathbuf))
197 char pathbuf[MAXPATHLEN+1]; local
[all...]
/freebsd-13-stable/lib/ncurses/ncurses/
H A Dtermcap.c112 char pathbuf[PBUFSIZ]; /* holds raw path of filenames */ local
113 char *pathvec[PVECSIZ]; /* to point to names in pathbuf */
121 p = pathbuf;
135 strncpy(pathbuf, termpath, PBUFSIZ);
138 strncpy(pathbuf, home, PBUFSIZ - 1); /* $HOME first */
139 pathbuf[PBUFSIZ - 2] = '\0'; /* -2 because we add a slash */
140 p += strlen(pathbuf); /* path, looking in */
143 strncpy(p, _PATH_DEF, PBUFSIZ - (p - pathbuf));
147 strncpy(pathbuf, cp, PBUFSIZ); /* still can be tokenized */
151 strcpy(pathbuf, _PATH_DEF_SE
[all...]
/freebsd-13-stable/usr.sbin/pw/
H A Dgrupd.c46 static char pathbuf[MAXPATHLEN]; local
48 snprintf(pathbuf, sizeof pathbuf, "%s/%s", conf.etcpath, file);
50 return (pathbuf);
H A Dpwupd.c50 static char pathbuf[MAXPATHLEN]; local
52 snprintf(pathbuf, sizeof pathbuf, "%s/%s", conf.etcpath, file);
54 return (pathbuf);
/freebsd-13-stable/contrib/tcsh/
H A Dglob.c468 struct strbuf pathbuf = strbuf_INIT; local
476 err = glob2(&pathbuf, pattern, pglob, no_match);
477 xfree(pathbuf.s);
487 glob2(struct strbuf *pathbuf, const Char *pattern, glob_t *pglob, int no_match) argument
501 strbuf_terminate(pathbuf);
503 if (Lstat(pathbuf->s, &sbuf))
507 pathbuf->s[pathbuf->len - 1] != SEP) &&
511 (Stat(pathbuf->s, &sbuf) == 0) &&
515 strbuf_append1(pathbuf, SE
564 glob3(struct strbuf *pathbuf, const Char *pattern, const Char *restpattern, const Char *pglobstar, glob_t *pglob, int no_match) argument
[all...]
H A Dtc.os.c1218 char pathbuf[MAXPATHLEN]; /* temporary pathname buffer */ local
1219 char *pnptr = &pathbuf[(sizeof pathbuf)-1]; /* pathname pointer */
1269 pnptr = strnrcpy(dirp->d_name, pnptr, pnptr - pathbuf);
1270 pnptr = strnrcpy("/", pnptr, pnptr - pathbuf);
1289 (void) chdir(strnrcpy(".", pnptr, pnptr - pathbuf));
1304 char pathbuf[MAXPATHLEN], nextpathbuf[MAXPATHLEN * 2]; local
1315 pathbuf[MAXPATHLEN - 1] = '\0';
1316 pathptr = &pathbuf[MAXPATHLEN - 1];
1404 pathptr = strnrcpy(pathptr, d->d_name, pathptr - pathbuf);
[all...]
/freebsd-13-stable/bin/ln/
H A Dln.c186 char pathbuf[PATH_MAX]; local
206 memcpy(pathbuf, ".", 2);
208 memcpy(pathbuf, path1, file1 - path1);
209 pathbuf[file1 - path1] = '\0';
211 if (stat(pathbuf, &sb1) != 0)
214 memcpy(pathbuf, ".", 2);
216 memcpy(pathbuf, path2, file2 - path2);
217 pathbuf[file2 - path2] = '\0';
219 if (stat(pathbuf, &sb2) != 0)
/freebsd-13-stable/crypto/heimdal/lib/roken/
H A Dglob.c496 Char pathbuf[MaxPathLen+1]; local
501 return(glob2(pathbuf, pathbuf, pattern, pglob, limit));
519 glob2(Char *pathbuf, Char *pathend, Char *pattern, glob_t *pglob, argument
533 if (g_lstat(pathbuf, &sb, pglob))
539 (g_stat(pathbuf, &sb, pglob) == 0) &&
545 return(globextend(pathbuf, pglob, limit));
563 return(glob3(pathbuf, pathend, pattern, p, pglob,
570 glob3(Char *pathbuf, Char *pathend, Char *pattern, Char *restpattern, argument
589 if ((dirp = g_opendir(pathbuf, pglo
[all...]
/freebsd-13-stable/usr.bin/mail/
H A Dfio.c68 char linebuf[LINESIZE], pathbuf[PATHSIZE]; local
72 (void)snprintf(pathbuf, sizeof(pathbuf), "%s/mail.XXXXXXXXXX", tmpdir);
73 if ((c = mkstemp(pathbuf)) == -1 || (mestmp = Fdopen(c, "r+")) == NULL)
74 err(1, "can't open %s", pathbuf);
75 (void)rm(pathbuf);
/freebsd-13-stable/contrib/sendmail/smrsh/
H A Dsmrsh.c151 char pathbuf[1000]; local
163 (void) sm_strlcpyn(pathbuf, sizeof pathbuf, 2, "PATH=", PATH);
164 newenv[0] = pathbuf;
/freebsd-13-stable/sbin/fsck_ffs/
H A Dpass2.c71 char pathbuf[MAXPATHLEN + 1]; local
170 getpathname(pathbuf, inp->i_number, inp->i_number);
173 "DIRECTORY", pathbuf,
177 "DIRECTORY", pathbuf,
233 getpathname(pathbuf, inp->i_parent, inp->i_number);
235 (uintmax_t)inp->i_number, pathbuf);
236 getpathname(pathbuf, inp->i_dotdot, inp->i_dotdot);
238 (uintmax_t)inp->i_dotdot, pathbuf);
239 getpathname(pathbuf, inp->i_parent, inp->i_parent);
241 (uintmax_t)inp->i_parent, pathbuf);
[all...]
H A Dinode.c71 char pathbuf[MAXPATHLEN + 1]; local
101 getpathname(pathbuf, idesc->id_number,
104 pathbuf);
141 getpathname(pathbuf, idesc->id_number,
144 pathbuf);
172 char pathbuf[MAXPATHLEN + 1]; local
227 getpathname(pathbuf, idesc->id_number,
230 pathbuf);
H A Ddir.c339 char pathbuf[MAXPATHLEN + 1]; local
350 getpathname(pathbuf, cwd, ino);
354 pathbuf);
356 pfatal("NAME=%s\n", pathbuf);
636 char pathbuf[MAXPATHLEN + 1]; local
658 getpathname(pathbuf, parent, parent);
659 if (expanddir(&ip, pathbuf) == 0) {
/freebsd-13-stable/contrib/ncurses/ncurses/tinfo/
H A Dread_termcap.c793 char pathbuf[PBUFSIZ]; /* holds raw path of filenames */ local
794 CGETENT_CONST char *pathvec[PVECSIZ]; /* point to names in pathbuf */
800 p = pathbuf;
812 _nc_str_init(&desc, pathbuf, sizeof(pathbuf));
837 *fname++ = pathbuf; /* tokenize path into vector of names */
1038 char pathbuf[PATH_MAX]; local
1073 _nc_SPRINTF(pathbuf, _nc_SLIMIT(sizeof(pathbuf))
1075 ADD_TC(pathbuf, filecoun
[all...]
/freebsd-13-stable/crypto/openssh/openbsd-compat/
H A Dglob.c612 Char pathbuf[MAXPATHLEN]; local
617 return(glob2(pathbuf, pathbuf+MAXPATHLEN-1,
618 pathbuf, pathbuf+MAXPATHLEN-1,
628 glob2(Char *pathbuf, Char *pathbuf_last, Char *pathend, Char *pathend_last, argument
642 if (g_lstat(pathbuf, &sb, pglob))
656 (g_stat(pathbuf, &sb, pglob) == 0) &&
664 return(globextend(pathbuf, pglob, limitp, &sb));
688 return(glob3(pathbuf, pathbuf_las
696 glob3(Char *pathbuf, Char *pathbuf_last, Char *pathend, Char *pathend_last, Char *pattern, Char *restpattern, Char *restpattern_last, glob_t *pglob, struct glob_lim *limitp) argument
[all...]
/freebsd-13-stable/lib/libc/gen/
H A Dglob-compat11.c599 Char pathbuf[MAXPATHLEN]; local
604 return (glob2(pathbuf, pathbuf, pathbuf + MAXPATHLEN - 1,
614 glob2(Char *pathbuf, Char *pathend, Char *pathend_last, Char *pattern, argument
628 if (g_lstat(pathbuf, &sb, pglob))
640 g_stat(pathbuf, &sb, pglob) == 0 &&
650 return (globextend(pathbuf, pglob, limit, NULL));
677 return (glob3(pathbuf, pathend, pathend_last, pattern,
684 glob3(Char *pathbuf, Cha argument
[all...]
H A Dglob.c631 Char pathbuf[MAXPATHLEN]; local
636 return (glob2(pathbuf, pathbuf, pathbuf + MAXPATHLEN - 1,
646 glob2(Char *pathbuf, Char *pathend, Char *pathend_last, Char *pattern, argument
660 if (g_lstat(pathbuf, &sb, pglob))
672 g_stat(pathbuf, &sb, pglob) == 0 &&
682 return (globextend(pathbuf, pglob, limit, NULL));
709 return (glob3(pathbuf, pathend, pathend_last, pattern,
716 glob3(Char *pathbuf, Cha argument
[all...]
/freebsd-13-stable/contrib/opie/
H A Dopiesu.c105 static char pathbuf[sizeof("PATH") + sizeof(DEFAULT_PATH) - 1] = "PATH="; variable
107 static char *cleanenv[] = {userbuf, homebuf, shellbuf, pathbuf, 0, 0};
274 strcat(pathbuf, DEFAULT_PATH);
/freebsd-13-stable/libexec/rtld-elf/
H A Dlibmap.c413 char pathbuf[64], *s, *t; local
415 if (n < sizeof(pathbuf) - 1)
416 s = pathbuf;
422 if (s != pathbuf)
/freebsd-13-stable/usr.bin/rpcgen/
H A Drpc_main.c81 static char pathbuf[MAXPATHLEN + 1]; variable
1143 if (strlcpy(pathbuf, argv[i],
1144 sizeof(pathbuf)) >= sizeof(pathbuf)
1145 || strlcat(pathbuf, "/cpp",
1146 sizeof(pathbuf)) >=
1147 sizeof(pathbuf)) {
1151 CPP = pathbuf;
/freebsd-13-stable/lib/libdpv/
H A Ddpv.c69 static char pathbuf[PATH_MAX]; variable
577 len = snprintf(pathbuf,
580 len = snprintf(pathbuf,
583 warnx("%s:%d:%s: pathbuf[%u] too small"
589 if ((output_out = open(pathbuf,
592 warn("%s", pathbuf);
/freebsd-13-stable/contrib/ntp/util/
H A Dntp-keygen.c320 char pathbuf[MAXFILENAME + 1]; local
482 if (RAND_file_name(pathbuf, sizeof(pathbuf)) == NULL) {
487 temp = RAND_load_file(pathbuf, -1);
491 pathbuf);
495 "Random seed file %s %u bytes\n", pathbuf, temp);
552 BIO_gets(bp, pathbuf,
555 if (strcmp(pathbuf,
558 else if (strcmp(pathbuf,
1968 char pathbuf[MAXFILENAM local
[all...]
/freebsd-13-stable/bin/ps/
H A Dps.c859 char pathbuf[PATH_MAX], pathbuf2[PATH_MAX], pathbuf3[PATH_MAX]; local
875 strlcpy(pathbuf, _PATH_DEV, sizeof(pathbuf));
876 strlcat(pathbuf, elem, sizeof(pathbuf));
877 ttypath = pathbuf;
878 if (strncmp(pathbuf, _PATH_TTY, strlen(_PATH_TTY)) == 0)
880 if (strncmp(pathbuf, _PATH_PTS, strlen(_PATH_PTS)) == 0)
882 if (strcmp(pathbuf, _PATH_CONSOLE) == 0)
/freebsd-13-stable/contrib/bmake/
H A Dutil.c242 char pathbuf[MAXPATHLEN], nextpathbuf[MAXPATHLEN * 2]; local
251 pathbuf[MAXPATHLEN - 1] = '\0';
252 pathptr = &pathbuf[MAXPATHLEN - 1];

Completed in 421 milliseconds

12