From 8937f520849e4c08d20f692d4f574654b54d591d Mon Sep 17 00:00:00 2001 From: jkar8572 Date: Tue, 23 Aug 2005 09:23:35 +0000 Subject: Some more fixes of verbose printing (Jan Kara) --- Changelog | 1 + quotacheck.c | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Changelog b/Changelog index ef30869..d7dfa2f 100644 --- a/Changelog +++ b/Changelog @@ -3,6 +3,7 @@ Changes in quota-tools from 3.13 to 3.14 * implemented nicer message formatting for warnquota(8) (Jan Kara) * quota(1) has -w option to supress line wrapping for long device names (Jan Kara) * quota(1) prints grace time even if hard limit is reached (Jan Kara) +* fixed journaled quota format detection in quotacheck (Jan Kara) Changes in quota-tools from 3.12 to 3.13 * fixed mistakes in several error messages, improved error reporting functions diff --git a/quotacheck.c b/quotacheck.c index c77cbd8..da6f80a 100644 --- a/quotacheck.c +++ b/quotacheck.c @@ -8,7 +8,7 @@ * New quota format implementation - Jan Kara - Sponsored by SuSE CR */ -#ident "$Id: quotacheck.c,v 1.48 2005/08/22 12:51:09 jkar8572 Exp $" +#ident "$Id: quotacheck.c,v 1.49 2005/08/23 09:23:35 jkar8572 Exp $" #include #include @@ -895,6 +895,8 @@ Please stop all programs writing to filesystem or use -m flag to force checking. goto out; } dirs_done++; + if (flags & FL_VERBOSE || flags & FL_VERYVERBOSE) + fputs(_("done\n"), stdout); if (ucheck) { sub_quota_file(mnt, USRQUOTA, USRQUOTA); sub_quota_file(mnt, USRQUOTA, GRPQUOTA); @@ -903,8 +905,6 @@ Please stop all programs writing to filesystem or use -m flag to force checking. sub_quota_file(mnt, GRPQUOTA, USRQUOTA); sub_quota_file(mnt, GRPQUOTA, GRPQUOTA); } - if (flags & FL_VERBOSE) - fputs(_("done\n"), stdout); debug(FL_DEBUG | FL_VERBOSE, _("Checked %d directories and %d files\n"), dirs_done, files_done); if (remounted) { @@ -965,7 +965,7 @@ jquota_err: space = option + strlen(option); if (space-option > sizeof(fmtbuf)) goto jquota_err; - sstrncpy(fmtbuf, option+1, space-option+1); + sstrncpy(fmtbuf, option+1, space-option); if ((fmt = name2fmt(fmtbuf)) == QF_ERROR) goto jquota_err; return fmt; -- cgit v1.2.3