Lines Matching refs:source

873 static fssh_status_t copy_entry(FSDomain *sourceDomain, const char *source,
895 copy_file_contents(const char *source, File *sourceFile, const char *target,
931 source, fssh_strerror(bytesRead));
943 copy_dir_contents(FSDomain *sourceDomain, const char *source,
955 // compose a new source path name
956 char *sourceEntry = make_path(source, entry->d_name);
958 fprintf(stderr, "Error: Failed to allocate source path!\n");
978 fprintf(stderr, "Error reading directory `%s': %s\n", source,
988 copy_attribute(const char *source, Node *sourceNode, const char *target,
1011 // read data from source
1017 "`%s': %s\n", name, source, fssh_strerror(bytesRead));
1039 copy_attributes(const char *source, Node *sourceNode, const char *target,
1050 "`%s': %s\n", name, source, fssh_strerror(error));
1055 error = copy_attribute(source, sourceNode, target, targetNode, name,
1063 source, fssh_strerror(numRead));
1072 copy_entry(FSDomain *sourceDomain, const char *source,
1077 if (!options.entryFilter.Filter(source))
1080 // open the source node
1082 fssh_status_t error = sourceDomain->Open(source,
1086 fprintf(stderr, "Error: Failed to open source path `%s': %s\n", source,
1100 // check, if it is a dir and, if so, whether source is a dir too
1115 // 1.1. target and source are dirs:
1119 // 1.2. source and/or target are no dirs
1132 // 1.2.1.1. !/force/, but both source and target are files
1144 // 1.2.1.2. !/force/, source or target isn't a file
1166 fprintf(stderr, "Error: Entry `%s' is a directory.\n", source);
1181 // read the source link
1187 fprintf(stderr, "Error: Failed to read symlink `%s': %s\n", source,
1213 error = copy_attributes(source, sourceNode, target, targetNode);
1220 error = copy_file_contents(source, sourceNode->ToFile(), target,
1223 error = copy_dir_contents(sourceDomain, source,
1377 const char *source = sources[i];
1378 FSDomain *sourceDomain = get_file_domain(source, source);
1382 // open the source node
1384 error = sourceDomain->Open(source,
1388 fprintf(stderr, "Error: Failed to open `%s': %s.\n", source,
1395 error = copy_attributes(source, sourceNode, target, targetNode);
1400 // get the source leaf name
1402 error = get_last_path_component(source, leafName, sizeof(leafName));
1405 "`%s': %s\n", source, fssh_strerror(error));
1410 // 1.1.1. source name is `.' or `..'
1413 // open the source dir
1415 error = sourceDomain->Open(source,
1420 fprintf(stderr, "Error: Failed to open `%s': %s.\n", source,
1430 "although it's last path component is `%s'\n", source,
1435 error = copy_dir_contents(sourceDomain, source, sourceDir,
1438 // 1.1.2. source has normal name
1440 // (copy_entry(<source>, <target>/<source leaf>))
1449 error = copy_entry(sourceDomain, source, targetDomain,
1456 // (copy_entry(<source>, <target>))
1459 // -> we create the target as a clone of the source
1460 // (copy_entry(<source>, <target>))
1461 error = copy_entry(sourceDomain, source, targetDomain, target,