X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/93272700d2eb85320ddf67f3bc1281dbe402f9f9..d62bcc17f303f30d1e3df1051b1390202a21cf9c:/flist.c diff --git a/flist.c b/flist.c index 35bbed1f..41acca35 100644 --- a/flist.c +++ b/flist.c @@ -53,7 +53,6 @@ extern int preserve_perms; extern int preserve_devices; extern int preserve_uid; extern int preserve_gid; -extern int preserve_times; extern int relative_paths; extern int implied_dirs; extern int copy_links; @@ -779,8 +778,8 @@ struct file_struct *make_file(char *fname, } else { io_error |= IOERR_GENERAL; - rprintf(FERROR, "readlink %s failed: %s\n", - full_fname(thisname), strerror(save_errno)); + rsyserr(FERROR, save_errno, "readlink %s failed", + full_fname(thisname)); } return NULL; } @@ -950,6 +949,10 @@ void send_file_name(int f, struct file_list *flist, char *fname, struct exclude_list_struct last_list = local_exclude_list; local_exclude_list.head = local_exclude_list.tail = NULL; send_directory(f, flist, f_name_to(file, fbuf)); + if (verbose > 2) { + rprintf(FINFO, "[%s] popping %sexclude list\n", + who_am_i(), local_exclude_list.debug_type); + } free_exclude_list(&local_exclude_list); local_exclude_list = last_list; } @@ -967,8 +970,7 @@ static void send_directory(int f, struct file_list *flist, char *dir) d = opendir(dir); if (!d) { io_error |= IOERR_GENERAL; - rprintf(FERROR, "opendir %s failed: %s\n", - full_fname(dir), strerror(errno)); + rsyserr(FERROR, errno, "opendir %s failed", full_fname(dir)); return; } @@ -1015,8 +1017,7 @@ static void send_directory(int f, struct file_list *flist, char *dir) } if (errno) { io_error |= IOERR_GENERAL; - rprintf(FERROR, "readdir(%s): (%d) %s\n", - dir, errno, strerror(errno)); + rsyserr(FERROR, errno, "readdir(%s)", dir); } closedir(d); @@ -1051,8 +1052,8 @@ struct file_list *send_file_list(int f, int argc, char *argv[]) io_start_buffering_out(f); if (filesfrom_fd >= 0) { if (argv[0] && !push_dir(argv[0])) { - rprintf(FERROR, "push_dir %s failed: %s\n", - full_fname(argv[0]), strerror(errno)); + rsyserr(FERROR, errno, "push_dir %s failed", + full_fname(argv[0])); exit_cleanup(RERR_FILESELECT); } use_ff_fd = 1; @@ -1089,8 +1090,8 @@ struct file_list *send_file_list(int f, int argc, char *argv[]) if (link_stat(fname, &st) != 0) { if (f != -1) { io_error |= IOERR_GENERAL; - rprintf(FERROR, "link_stat %s failed: %s\n", - full_fname(fname), strerror(errno)); + rsyserr(FERROR, errno, "link_stat %s failed", + full_fname(fname)); } continue; } @@ -1159,8 +1160,8 @@ struct file_list *send_file_list(int f, int argc, char *argv[]) if (!push_dir(dir)) { io_error |= IOERR_GENERAL; - rprintf(FERROR, "push_dir %s failed: %s\n", - full_fname(dir), strerror(errno)); + rsyserr(FERROR, errno, "push_dir %s failed", + full_fname(dir)); continue; } @@ -1182,8 +1183,8 @@ struct file_list *send_file_list(int f, int argc, char *argv[]) flist_dir = NULL; flist_dir_len = 0; if (!pop_dir(olddir)) { - rprintf(FERROR, "pop_dir %s failed: %s\n", - full_fname(dir), strerror(errno)); + rsyserr(FERROR, errno, "pop_dir %s failed", + full_fname(dir)); exit_cleanup(RERR_FILESELECT); } }