diff options
author | Wayne Davison <wayned@samba.org> | 2008-07-13 20:51:08 -0700 |
---|---|---|
committer | Wayne Davison <wayned@samba.org> | 2008-07-13 20:51:08 -0700 |
commit | 951e826b75c4a4e6bc066e248d7489fb6eba6fde (patch) | |
tree | 64352078b8e10472e8a6af286dbb4cc5b6214f3d /hlink.c | |
parent | d8d13893489ba8245d2ff1e67fbb5c46dd047ef6 (diff) | |
download | rsync-951e826b75c4a4e6bc066e248d7489fb6eba6fde.tar.gz rsync-951e826b75c4a4e6bc066e248d7489fb6eba6fde.tar.bz2 rsync-951e826b75c4a4e6bc066e248d7489fb6eba6fde.zip |
Added the --info=FLAGS an --debug=FLAGS options, which allows
fine-grained output control (in addition to the coarse -v).
Diffstat (limited to 'hlink.c')
-rw-r--r-- | hlink.c | 11 |
1 files changed, 5 insertions, 6 deletions
@@ -22,7 +22,6 @@ #include "rsync.h" -extern int verbose; extern int dry_run; extern int list_only; extern int am_sender; @@ -215,7 +214,7 @@ static int maybe_hard_link(struct file_struct *file, int ndx, ITEM_LOCAL_CHANGE | ITEM_XNAME_FOLLOWS, 0, ""); } - if (verbose > 1 && maybe_ATTRS_REPORT) + if (INFO_GTE(NAME, 2) && maybe_ATTRS_REPORT) rprintf(FCLIENT, "%s is uptodate\n", fname); file->flags |= FLAG_HLINK_DONE; return 0; @@ -236,7 +235,7 @@ static int maybe_hard_link(struct file_struct *file, int ndx, ITEM_LOCAL_CHANGE | ITEM_XNAME_FOLLOWS, 0, realname); } - if (code != FNONE && verbose) + if (code != FNONE && INFO_GTE(NAME, 1)) rprintf(code, "%s => %s\n", fname, realname); return 0; } @@ -377,10 +376,10 @@ int hard_link_check(struct file_struct *file, int ndx, const char *fname, continue; statret = 1; if (stdout_format_has_i == 0 - || (verbose < 2 && stdout_format_has_i < 2)) { + || (!INFO_GTE(NAME, 2) && stdout_format_has_i < 2)) { itemizing = 0; code = FNONE; - if (verbose > 1 && maybe_ATTRS_REPORT) + if (INFO_GTE(NAME, 2) && maybe_ATTRS_REPORT) rprintf(FCLIENT, "%s is uptodate\n", fname); } break; @@ -426,7 +425,7 @@ int hard_link_one(struct file_struct *file, const char *fname, if (do_link(oldname, fname) < 0) { enum logcode code; if (terse) { - if (!verbose) + if (!INFO_GTE(NAME, 1)) return 0; code = FINFO; } else |