diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2019-07-22 14:53:37 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2019-07-22 14:53:37 +0300 |
commit | b369ed6ad26c07d3aec65a1bf0910c0d828c400f (patch) | |
tree | 525b13a5bbda244cbec3fe10c25c47aa2975e2a5 /src/diskio.c | |
parent | 0917d1276103d9cc893e8ac091e9e63c5e6182f8 (diff) | |
download | wydawca-b369ed6ad26c07d3aec65a1bf0910c0d828c400f.tar.gz wydawca-b369ed6ad26c07d3aec65a1bf0910c0d828c400f.tar.bz2 |
Finish mod_logstat implementation. Document it.
* doc/wydawca.texi: Document mod_logstat.
* include/wydawca/wydawca.h (wy_ev_statistics): Rename to
wy_ev_finish. All uses changed.
(wydawca_stat): New enum (from src/wydawca.h)
(WY_STAT_MASK,WY_STAT_MASK_NONE)
(WY_STAT_MASK_ALL): New macros.
All uses changed.
* modules/logstat/mod_logstat.c (stat_mask): Default to WY_STAT_MASK_ALL.
(wy_notify): Provide default output.
Diffstat (limited to 'src/diskio.c')
-rw-r--r-- | src/diskio.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/diskio.c b/src/diskio.c index 7916b3f..a86997e 100644 --- a/src/diskio.c +++ b/src/diskio.c @@ -237,7 +237,7 @@ tar_append_file(const char *archive, const char *file) wy_debug(1, (_("tarring %s to %s"), file, archive)); if (wy_dry_run) { - UPDATE_STATS(STAT_ARCHIVES); + UPDATE_STATS(WY_STAT_ARCHIVES); return 0; } @@ -250,7 +250,7 @@ tar_append_file(const char *archive, const char *file) switch (wydawca_exec(6, argv, NULL)) { case exec_success: - UPDATE_STATS(STAT_ARCHIVES); + UPDATE_STATS(WY_STAT_ARCHIVES); return 0; case exec_fail: @@ -351,13 +351,13 @@ do_archive_file(const char *dst_file, const char *dst_dir, const char *file, case archive_directory: if (backup_file(dst_file, dst_dir, file, archive, reldir)) return 1; - UPDATE_STATS(STAT_ARCHIVES); + UPDATE_STATS(WY_STAT_ARCHIVES); break; case archive_tar: if (tar_append_file(archive->name, dst_file)) return 1; - UPDATE_STATS(STAT_ARCHIVES); + UPDATE_STATS(WY_STAT_ARCHIVES); break; } @@ -431,7 +431,7 @@ dir_move_file(struct wy_triplet *trp, enum file_type file_id) free(dst_file); free(dst_dir); if (rc == 0) - UPDATE_STATS(STAT_UPLOADS); + UPDATE_STATS(WY_STAT_UPLOADS); return rc; } @@ -616,7 +616,7 @@ dir_symlink_file(struct wy_triplet *trp, free(dst); free(dst_dir); if (rc == 0) - UPDATE_STATS(STAT_SYMLINKS); + UPDATE_STATS(WY_STAT_SYMLINKS); return rc; } @@ -648,7 +648,7 @@ do_rmsymlink_file(const char *dst_file, int noentok) strerror(errno)); return 1; } - UPDATE_STATS(STAT_RMSYMLINKS); + UPDATE_STATS(WY_STAT_RMSYMLINKS); return 0; } |