diff mbox

libquota: fix get_dq()

Message ID 4EBCB11A.8000203@whamcloud.com
State Accepted, archived
Headers show

Commit Message

Niu Nov. 11, 2011, 5:22 a.m. UTC
Hi, Aditya

This one more fix based on your new quota patches.

From f3f4de997890a0c50d7c8143d9046dcab93cda5d Mon Sep 17 00:00:00 2001
From: Niu Yawei <niu@whamcloud.com>
Date: Fri, 11 Nov 2011 01:11:59 +0800
Subject: [PATCH] libquota: fix get_dq()

The dq_id should be set on newly created dqout.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
---
 lib/quota/mkquota.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Comments

Theodore Ts'o Nov. 14, 2011, 4:56 p.m. UTC | #1
On Fri, Nov 11, 2011 at 01:22:34PM +0800, Niu wrote:
> Hi, Aditya
> 
> This one more fix based on your new quota patches.
> 
> From f3f4de997890a0c50d7c8143d9046dcab93cda5d Mon Sep 17 00:00:00 2001
> From: Niu Yawei <niu@whamcloud.com>
> Date: Fri, 11 Nov 2011 01:11:59 +0800
> Subject: [PATCH] libquota: fix get_dq()
> 
> The dq_id should be set on newly created dqout.
> 
> Signed-off-by: Niu Yawei <niu@whamcloud.com>

Applied, thanks.

						- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/lib/quota/mkquota.c b/lib/quota/mkquota.c
index 832b135..ac7288c 100644
--- a/lib/quota/mkquota.c
+++ b/lib/quota/mkquota.c
@@ -292,6 +292,7 @@  static struct dquot *get_dq(dict_t *dict, __u32 key)
 		}
 		memset(dq, 0, sizeof(struct dquot));
 		dict_alloc_insert(dict, UINT_TO_VOIDPTR(key), dq);
+		dq->dq_id = key;
 	}
 	return dq;
 }