Lines Matching refs:source
483 lnkfil(const char *source, char *target) in lnkfil() argument
498 len = strlen(target) + strlen(dname(source)) + 4; in lnkfil()
502 "to %s %s\n"), cmd, cmd, source); in lnkfil()
506 target, dname(source)); in lnkfil()
573 if (symlink(source, target) < 0) { in lnkfil()
587 switch (chkfiles(source, &target)) { in lnkfil()
603 gettext("%s: %s is a directory\n"), cmd, source); in lnkfil()
611 if (link(source, target) < 0) { in lnkfil()
633 cpymve(const char *source, char *target) in cpymve() argument
643 switch (chkfiles(source, &target)) { in cpymve()
681 cmd, source); in cpymve()
683 Perror(source); in cpymve()
689 rc = copydir(source, target); in cpymve()
701 Perror(source); in cpymve()
719 if (rename(source, target) >= 0) in cpymve()
725 cmd, source); in cpymve()
730 cmd, source, target); in cpymve()
744 " %s \n"), cmd, source, target); in cpymve()
762 if ((n = copydir(source, target)) == 0) in cpymve()
763 (void) rmdir(source); in cpymve()
771 "across file systems\n"), cmd, source); in cpymve()
779 "across file systems\n"), cmd, source); in cpymve()
801 if ((m = readlink(source, symln, in cpymve()
803 Perror(source); in cpymve()
879 m = readlink(source, symln, sizeof (symln) - 1); in cpymve()
882 Perror(source); in cpymve()
914 fi = open(source, O_RDONLY); in cpymve()
918 cmd, source); in cpymve()
982 cmd, source); in cpymve()
989 cmd, source, target); in cpymve()
993 if (writefile(fi, fo, source, target, NULL, in cpymve()
1006 attret = copyattributes(source, target); in cpymve()
1011 " %s\n"), cmd, source); in cpymve()
1015 sattret = copy_sysattr(source, target); in cpymve()
1062 source, (s1.st_mode & S_IFMT)); in cpymve()
1066 if (unlink(source) < 0) { in cpymve()
1070 cmd, source); in cpymve()
1110 chkfiles(const char *source, char **to) in chkfiles() argument
1121 if ((*statf)(source, &s1) < 0) { in chkfiles()
1128 (void) fprintf(stderr, "%s: %s: %s\n", cmd, source, in chkfiles()
1132 gettext("%s: cannot access %s\n"), cmd, source); in chkfiles()
1144 if ((error = acl_get(source, ACL_NO_TRIVIAL, &s1acl)) != 0) { in chkfiles()
1146 "%s: failed to get acl entries: %s\n", source, in chkfiles()
1171 len = strlen(target) + strlen(dname(source)) + 4; in chkfiles()
1175 "%s %s\n "), cmd, cmd, source); in chkfiles()
1179 target, dname(source)); in chkfiles()
1203 cmd, source, target); in chkfiles()
1216 if (!chk_different(source, target)) { in chkfiles()
1365 chk_different(const char *source, const char *target) in chk_different() argument
1374 if ((getrealpath(source, rsource) == 0) || in chk_different()
1381 cmd, source, target); in chk_different()
1642 copydir(const char *source, char *target) argument
1656 gettext("%s: %s: is a directory\n"), cmd, source);
1707 ret = rcopy(source, target);
1748 attret = copyattributes(source, target);
1752 " %s\n"), cmd, source);
1761 sattret = copy_sysattr(source, target);
1766 "of directory %s\n"), cmd, source);
1808 copyattributes(const char *source, const char *target) argument
1820 if (pathconf(source, _PC_XATTR_EXISTS) != 1)
1833 if (open_source(source) != 0)
1835 if (open_target_srctarg_attrdirs(source, target) != 0)
1837 if (open_attrdirp(source) != 0)
1889 source, acl_strerror(aclerror));
1912 if ((ret = traverse_attrfile(dp, source, target, 1)) == -1)
1927 source, acl_strerror(aclerror));
1950 if (writefile(srcattrfd, targattrfd, source, target,
2047 copy_sysattr(const char *source, const char *target) argument
2054 if (sysattr_support(source, _PC_SATTR_EXISTS) != 1)
2057 if (open_source(source) != 0)
2066 response = sysattr_list(cmd, srcfd, source);
2084 if (open_target_srctarg_attrdirs(source,
2089 if (open_attrdirp(source) != 0) {
2100 if ((ret = traverse_attrfile(dp, source, target,
2128 dp->d_name, source, target);
2146 "%s to %s\n"), cmd, source, target);
2256 open_attrdirp(const char *source) argument
2276 " file descriptor for %s: "), cmd, source);
2290 " directory for %s: "), cmd, source);
2303 traverse_attrfile(struct dirent *dp, const char *source, const char *target, argument
2322 " file %s: "), cmd, dp->d_name, source);
2334 " %s: "), cmd, dp->d_name, source);