Lines Matching refs:source
381 lnkfil(char *source, char *target) in lnkfil() argument
396 len = strlen(target) + strlen(dname(source)) + 4; in lnkfil()
400 "to %s %s\n"), cmd, cmd, source); in lnkfil()
404 target, dname(source)); in lnkfil()
450 if (symlink(source, target) < 0) { in lnkfil()
464 switch (chkfiles(source, &target)) { in lnkfil()
477 gettext("%s: %s is a directory\n"), cmd, source); in lnkfil()
485 if (link(source, target) < 0) { in lnkfil()
507 cpymve(char *source, char *target) in cpymve() argument
517 switch (chkfiles(source, &target)) { in cpymve()
552 cmd, source); in cpymve()
554 Perror(source); in cpymve()
560 rc = copydir(source, target); in cpymve()
572 Perror(source); in cpymve()
590 if (rename(source, target) >= 0) in cpymve()
596 cmd, source); in cpymve()
601 cmd, source, target); in cpymve()
615 " %s \n"), cmd, source, target); in cpymve()
633 if ((n = copydir(source, target)) == 0) in cpymve()
634 (void) rmdir(source); in cpymve()
642 "across file systems\n"), cmd, source); in cpymve()
650 "across file systems\n"), cmd, source); in cpymve()
672 if ((m = readlink(source, symln, in cpymve()
674 Perror(source); in cpymve()
750 m = readlink(source, symln, sizeof (symln) - 1); in cpymve()
753 Perror(source); in cpymve()
785 fi = open(source, O_RDONLY); in cpymve()
789 cmd, source); in cpymve()
853 cmd, source); in cpymve()
860 cmd, source, target); in cpymve()
864 if (writefile(fi, fo, source, target, NULL, in cpymve()
877 attret = copyattributes(source, target); in cpymve()
882 " %s\n"), cmd, source); in cpymve()
886 sattret = copy_sysattr(source, target); in cpymve()
933 source, (s1.st_mode & S_IFMT)); in cpymve()
937 if (unlink(source) < 0) { in cpymve()
941 cmd, source); in cpymve()
981 chkfiles(char *source, char **to) in chkfiles() argument
992 if ((*statf)(source, &s1) < 0) { in chkfiles()
999 (void) fprintf(stderr, "%s: %s: %s\n", cmd, source, in chkfiles()
1003 gettext("%s: cannot access %s\n"), cmd, source); in chkfiles()
1015 if ((error = acl_get(source, ACL_NO_TRIVIAL, &s1acl)) != 0) { in chkfiles()
1017 "%s: failed to get acl entries: %s\n", source, in chkfiles()
1042 len = strlen(target) + strlen(dname(source)) + 4; in chkfiles()
1046 "%s %s\n "), cmd, cmd, source); in chkfiles()
1050 target, dname(source)); in chkfiles()
1073 cmd, source, target); in chkfiles()
1086 if (!chk_different(source, target)) { in chkfiles()
1183 chk_different(char *source, char *target) in chk_different() argument
1192 if ((getrealpath(source, rsource) == 0) || in chk_different()
1199 cmd, source, target); in chk_different()
1449 copydir(char *source, char *target) argument
1463 gettext("%s: %s: is a directory\n"), cmd, source);
1514 ret = rcopy(source, target);
1555 attret = copyattributes(source, target);
1559 " %s\n"), cmd, source);
1568 sattret = copy_sysattr(source, target);
1573 "of directory %s\n"), cmd, source);
1615 copyattributes(char *source, char *target) argument
1627 if (pathconf(source, _PC_XATTR_EXISTS) != 1)
1640 if (open_source(source) != 0)
1642 if (open_target_srctarg_attrdirs(source, target) != 0)
1644 if (open_attrdirp(source) != 0)
1696 source, acl_strerror(aclerror));
1719 if ((ret = traverse_attrfile(dp, source, target, 1)) == -1)
1734 source, acl_strerror(aclerror));
1757 if (writefile(srcattrfd, targattrfd, source, target,
1854 copy_sysattr(char *source, char *target) argument
1861 if (sysattr_support(source, _PC_SATTR_EXISTS) != 1)
1864 if (open_source(source) != 0)
1873 response = sysattr_list(cmd, srcfd, source);
1891 if (open_target_srctarg_attrdirs(source,
1896 if (open_attrdirp(source) != 0) {
1907 if ((ret = traverse_attrfile(dp, source, target,
1936 dp->d_name, source, target);
1955 "%s to %s\n"), cmd, source, target);
2066 open_attrdirp(char *source) argument
2086 " file descriptor for %s: "), cmd, source);
2100 " directory for %s: "), cmd, source);
2113 traverse_attrfile(struct dirent *dp, char *source, char *target, int first) argument
2131 " file %s: "), cmd, dp->d_name, source);
2143 " %s: "), cmd, dp->d_name, source);