Lines Matching refs:pathname

425 	char *file;		/* full pathname */
656 static bool check_path_allow_restorecon(const char *pathname)
658 if ((!strncmp(pathname, DATA_APP_EL1, sizeof(DATA_APP_EL1) - 1) && (!is_hnp_path(pathname))) ||
659 !strncmp(pathname, DATA_APP_EL2, sizeof(DATA_APP_EL2) - 1) ||
660 !strncmp(pathname, DATA_APP_EL3, sizeof(DATA_APP_EL3) - 1) ||
661 !strncmp(pathname, DATA_APP_EL4, sizeof(DATA_APP_EL4) - 1) ||
662 !strncmp(pathname, DATA_ACCOUNTS_ACCOUNT_0, sizeof(DATA_ACCOUNTS_ACCOUNT_0) - 1)) {
669 static int restorecon_sb(const char *pathname, const struct stat *sb,
676 const char *lookup_path = pathname;
678 if (!check_path_allow_restorecon(pathname)) {
730 rc = filespec_add(sb->st_ino, newcon, pathname, flags);
734 "filespec_add error: %s\n", pathname);
748 pathname, newcon);
750 if (lgetfilecon_raw(pathname, &curcon) < 0) {
765 pathname, curcon);
785 if (lsetfilecon(pathname, newcon) < 0)
794 pathname,
802 pathname, curcon, newcon);
805 pathname, newcon);
818 pathname);
833 static bool check_context_match_for_dir(const char *pathname,
848 status = selabel_get_digests_all_partial_matches(fc_sehandle, pathname,
863 (*new_node)->path = strdup(pathname);
1146 char *pathname = NULL, *pathdnamer = NULL, *pathdname, *pathbname;
1186 * Convert passed-in pathname to canonical pathname by resolving
1196 pathname = realpath(pathname_orig, NULL);
1197 if (!pathname) {
1222 error = asprintf(&pathname, "/%s", pathbname);
1224 error = asprintf(&pathname, "%s/%s",
1233 pathname = strdup(pathname_orig);
1234 if (!pathname)
1238 paths[0] = pathname;
1240 if (lstat(pathname, &sb) < 0) {
1243 free(pathname);
1248 pathname);
1259 if (check_excluded(pathname)) {
1264 error = restorecon_sb(pathname, &sb, &state.flags, true);
1270 if (!S_ISLNK(sb.st_mode) && statfs(pathname, &state.sfsb) < 0) {
1273 pathname);
1390 fprintf(stdout, "\r%s 100.0%%\n", pathname);
1401 free(pathname);
1546 int selinux_restorecon_xattr(const char *pathname, unsigned int xattr_flags,
1571 if (lstat(pathname, &sb) < 0) {
1577 pathname);
1582 if (statfs(pathname, &sfsb) == 0) {
1588 if (check_excluded(pathname))
1591 rc = add_xattr_entry(pathname, delete_nonmatch, delete_all);
1601 paths[0] = (char *)pathname;