Module Name: src Committed By: bouyer Date: Sat Mar 5 18:10:44 UTC 2011
Modified Files: src/usr.bin/quota [bouyer-quota2]: quota.c src/usr.sbin/edquota [bouyer-quota2]: edquota.c src/usr.sbin/repquota [bouyer-quota2]: repquota.c Log Message: The new quotactl interface should be filesystem-independant, so check only the MNT_QUOTA flag. To generate a diff of this commit: cvs rdiff -u -r1.33.2.9 -r1.33.2.10 src/usr.bin/quota/quota.c cvs rdiff -u -r1.29.16.11 -r1.29.16.12 src/usr.sbin/edquota/edquota.c cvs rdiff -u -r1.25.2.8 -r1.25.2.9 src/usr.sbin/repquota/repquota.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/usr.bin/quota/quota.c diff -u src/usr.bin/quota/quota.c:1.33.2.9 src/usr.bin/quota/quota.c:1.33.2.10 --- src/usr.bin/quota/quota.c:1.33.2.9 Mon Feb 14 20:38:56 2011 +++ src/usr.bin/quota/quota.c Sat Mar 5 18:10:44 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: quota.c,v 1.33.2.9 2011/02/14 20:38:56 bouyer Exp $ */ +/* $NetBSD: quota.c,v 1.33.2.10 2011/03/05 18:10:44 bouyer Exp $ */ /* * Copyright (c) 1980, 1990, 1993 @@ -42,7 +42,7 @@ #if 0 static char sccsid[] = "@(#)quota.c 8.4 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: quota.c,v 1.33.2.9 2011/02/14 20:38:56 bouyer Exp $"); +__RCSID("$NetBSD: quota.c,v 1.33.2.10 2011/03/05 18:10:44 bouyer Exp $"); #endif #endif /* not lint */ @@ -507,9 +507,7 @@ version = 0; if (getnfsquota(&fst[i], NULL, qup, id, quotatype) == 0) continue; - } else if (strncmp(fst[i].f_fstypename, "ffs", - sizeof(fst[i].f_fstypename)) == 0 && - (fst[i].f_flag & ST_QUOTA) != 0) { + } else if ((fst[i].f_flag & ST_QUOTA) != 0) { if (getvfsquota(fst[i].f_mntonname, &qup->q2e, &version, id, quotatype, dflag, Dflag) == 0) continue; Index: src/usr.sbin/edquota/edquota.c diff -u src/usr.sbin/edquota/edquota.c:1.29.16.11 src/usr.sbin/edquota/edquota.c:1.29.16.12 --- src/usr.sbin/edquota/edquota.c:1.29.16.11 Wed Feb 9 17:48:45 2011 +++ src/usr.sbin/edquota/edquota.c Sat Mar 5 18:10:44 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: edquota.c,v 1.29.16.11 2011/02/09 17:48:45 bouyer Exp $ */ +/* $NetBSD: edquota.c,v 1.29.16.12 2011/03/05 18:10:44 bouyer Exp $ */ /* * Copyright (c) 1980, 1990, 1993 * The Regents of the University of California. All rights reserved. @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "from: @(#)edquota.c 8.3 (Berkeley) 4/27/95"; #else -__RCSID("$NetBSD: edquota.c,v 1.29.16.11 2011/02/09 17:48:45 bouyer Exp $"); +__RCSID("$NetBSD: edquota.c,v 1.29.16.12 2011/03/05 18:10:44 bouyer Exp $"); #endif #endif /* not lint */ @@ -386,8 +386,7 @@ errx(2, "no filesystems mounted!"); for (i = 0; i < nfst; i++) { - if (strcmp(fst[i].f_fstypename, "ffs") != 0 || - (fst[i].f_flag & ST_QUOTA) == 0) + if ((fst[i].f_flag & ST_QUOTA) == 0) continue; if (filesys && strcmp(fst[i].f_mntonname, filesys) != 0 && strcmp(fst[i].f_mntfromname, filesys) != 0) @@ -1123,8 +1122,7 @@ errx(2, "no filesystems mounted!"); for (i = 0; i < nfst; i++) { - if (strcmp(fst[i].f_fstypename, "ffs") != 0 || - (fst[i].f_flag & ST_QUOTA) == 0) + if ((fst[i].f_flag & ST_QUOTA) == 0) continue; if (filesys && strcmp(fst[i].f_mntonname, filesys) != 0 && strcmp(fst[i].f_mntfromname, filesys) != 0) Index: src/usr.sbin/repquota/repquota.c diff -u src/usr.sbin/repquota/repquota.c:1.25.2.8 src/usr.sbin/repquota/repquota.c:1.25.2.9 --- src/usr.sbin/repquota/repquota.c:1.25.2.8 Mon Feb 14 20:55:36 2011 +++ src/usr.sbin/repquota/repquota.c Sat Mar 5 18:10:44 2011 @@ -40,7 +40,7 @@ #if 0 static char sccsid[] = "@(#)repquota.c 8.2 (Berkeley) 11/22/94"; #else -__RCSID("$NetBSD: repquota.c,v 1.25.2.8 2011/02/14 20:55:36 bouyer Exp $"); +__RCSID("$NetBSD: repquota.c,v 1.25.2.9 2011/03/05 18:10:44 bouyer Exp $"); #endif #endif /* not lint */ @@ -173,9 +173,7 @@ if (nfst == 0) errx(2, "no filesystems mounted!"); for (i = 0; i < nfst; i++) { - if (strncmp(fst[i].f_fstypename, "ffs", - sizeof(fst[i].f_fstypename)) != 0 || - (fst[i].f_flag & ST_QUOTA) == 0) + if ((fst[i].f_flag & ST_QUOTA) == 0) continue; if (aflag) { if (gflag)