summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Changelog5
-rw-r--r--quota.c6
-rw-r--r--quotasys.c8
3 files changed, 12 insertions, 7 deletions
diff --git a/Changelog b/Changelog
index d586d45..43ff6b1 100644
--- a/Changelog
+++ b/Changelog
@@ -1,3 +1,8 @@
+Changes in quota-tools from 3.05 to 3.06
+* fixed scanning of non-mountpoint directories (Jan Kara)
+* fixed detection of XFS format (Jan Kara)
+* fixed printing of 'over softlimit sign' in quota(1) (Jan Kara)
+
Changes in quota-tools from 3.04 to 3.05
* quota tools should honour 'noquota' mount option (Jan Kara)
* fixes in manpages (Arkadiusz Miskiewicz)
diff --git a/quota.c b/quota.c
index a4d9903..65ced8f 100644
--- a/quota.c
+++ b/quota.c
@@ -34,7 +34,7 @@
#ident "$Copyright: (c) 1980, 1990 Regents of the University of California. $"
#ident "$Copyright: All rights reserved. $"
-#ident "$Id: quota.c,v 1.10 2002/04/08 12:06:44 jkar8572 Exp $"
+#ident "$Id: quota.c,v 1.11 2002/05/20 12:16:31 jkar8572 Exp $"
/*
* Disk quota reporting program.
@@ -173,7 +173,7 @@ int showquotas(int type, qid_t id)
iover = 1;
}
else if (q->dq_dqb.dqb_isoftlimit
- && q->dq_dqb.dqb_curinodes >= q->dq_dqb.dqb_isoftlimit) {
+ && q->dq_dqb.dqb_curinodes > q->dq_dqb.dqb_isoftlimit) {
if (q->dq_dqb.dqb_itime > now) {
msgi = _("In file grace period on");
iover = 2;
@@ -189,7 +189,7 @@ int showquotas(int type, qid_t id)
bover = 1;
}
else if (q->dq_dqb.dqb_bsoftlimit
- && toqb(q->dq_dqb.dqb_curspace) >= q->dq_dqb.dqb_bsoftlimit) {
+ && toqb(q->dq_dqb.dqb_curspace) > q->dq_dqb.dqb_bsoftlimit) {
if (q->dq_dqb.dqb_btime > now) {
msgb = _("In block grace period on");
bover = 2;
diff --git a/quotasys.c b/quotasys.c
index 4123542..b610297 100644
--- a/quotasys.c
+++ b/quotasys.c
@@ -520,6 +520,8 @@ void init_kernel_interface(void)
struct stat st;
kernel_formats = 0;
+ if (!stat("/proc/fs/xfs/stat", &st))
+ kernel_formats |= (1 << QF_XFS);
if ((f = fopen(QSTAT_FILE, "r"))) {
/* Parse statistics file */
fgets(buf, sizeof(buf), f);
@@ -545,8 +547,6 @@ void init_kernel_interface(void)
struct v2_dqstats v2_stats;
struct sigaction sig, oldsig;
- if (!stat("/proc/fs/xfs/stat", &st))
- kernel_formats |= (1 << QF_XFS);
/* This signal handling is needed because old kernels send us SIGSEGV as they try to resolve the device */
sig.sa_handler = SIG_IGN;
sig.sa_sigaction = NULL;
@@ -821,7 +821,7 @@ static int cache_mnt_table(void)
}
/* Find mountpoint of filesystem hosting dir in 'st'; Store it in 'st' */
-static char *find_dir_mntpoint(struct stat *st)
+static const char *find_dir_mntpoint(struct stat *st)
{
int i;
@@ -851,7 +851,7 @@ static int process_dirs(int dcnt, char **dirs, int flags)
}
check_dirs[check_dirs_cnt].sd_dir = S_ISDIR(st.st_mode);
if (S_ISDIR(st.st_mode)) {
- char *realmnt = dirs[i];
+ const char *realmnt = dirs[i];
/* Return st of mountpoint of dir in st.. */
if (flags & MS_NO_MNTPOINT && !(realmnt = find_dir_mntpoint(&st))) {