summaryrefslogtreecommitdiffstats
path: root/fs/dquot.c
diff options
context:
space:
mode:
authorMiguel de Icaza <miguel@nuclecu.unam.mx>1997-08-06 19:14:48 +0000
committerMiguel de Icaza <miguel@nuclecu.unam.mx>1997-08-06 19:14:48 +0000
commite2819e52a162873ff5061de81bb749831bdb5de9 (patch)
tree6067ea700202750ba335a423696f2972700e5f76 /fs/dquot.c
parent17a005074429bbf143e40401f405ae4363e56828 (diff)
Merge to 2.1.38.
IMPORTANT NOTE: I could not figure out what information is the one that should be used for the following files (ie, those that were in our tree, or those that came from Linus' patch), please, check these: include/asm-mips/jazz.h include/asm-mips/jazzdma.h include/asm-mips/ioctls.h
Diffstat (limited to 'fs/dquot.c')
-rw-r--r--fs/dquot.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/fs/dquot.c b/fs/dquot.c
index b19c939be..410e33999 100644
--- a/fs/dquot.c
+++ b/fs/dquot.c
@@ -13,13 +13,15 @@
* diskquota system. This implementation is not based on any BSD
* kernel sourcecode.
*
- * Version: $Id: dquot.c,v 1.2 1997/06/17 13:25:58 ralf Exp $
+ * Version: $Id: dquot.c,v 1.3 1997/07/20 14:59:17 ralf Exp $
*
* Author: Marco van Wieringen <mvw@mcs.ow.nl> <mvw@tnix.net>
*
* Fixes: Dmitry Gorodchanin <begemot@bgm.rosprint.net>, 11 Feb 96
* removed race conditions in dqput(), dqget() and iput().
* Andi Kleen removed all verify_area() calls, 31 Dec 96
+ * Nick Kralevich <nickkral@cal.alumni.berkeley.edu>, 21 Jul 97
+ * Fixed a condition where user and group quotas could get mixed up.
*
* (C) Copyright 1994, 1995 Marco van Wieringen
*
@@ -555,12 +557,14 @@ static struct dquot *dqget(kdev_t dev, unsigned int id, short type)
repeat:
dquot = *(hash(dev, id, type));
while (dquot) {
- if (dquot->dq_dev != dev || dquot->dq_id != id) {
+ if (dquot->dq_dev != dev || dquot->dq_id != id ||
+ dquot->dq_type != type) {
dquot = dquot->dq_hash_next;
continue;
}
wait_on_dquot(dquot);
- if (dquot->dq_dev != dev || dquot->dq_id != id)
+ if (dquot->dq_dev != dev || dquot->dq_id != id ||
+ dquot->dq_type != type)
goto repeat;
if (!dquot->dq_count)
nr_free_dquots--;