aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jffs2/nodelist.c
diff options
context:
space:
mode:
authorArtem B. Bityutskiy <dedekind@infradead.org>2005-08-04 12:40:02 +0100
committerThomas Gleixner <tglx@mtd.linutronix.de>2005-11-06 18:35:36 +0100
commit3c09133739beff0d5ad457dfcfc85c7c350d3661 (patch)
tree171320f1919f6be98a90a08c3a88d84120456967 /fs/jffs2/nodelist.c
parent392435081e8cc6e02bdc4fa998050abb11d331b4 (diff)
downloadkernel_samsung_tuna-3c09133739beff0d5ad457dfcfc85c7c350d3661.zip
kernel_samsung_tuna-3c09133739beff0d5ad457dfcfc85c7c350d3661.tar.gz
kernel_samsung_tuna-3c09133739beff0d5ad457dfcfc85c7c350d3661.tar.bz2
[JFFS2] Correct buggy length checks
The previous changes introduced wrong length calculations. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'fs/jffs2/nodelist.c')
-rw-r--r--fs/jffs2/nodelist.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/jffs2/nodelist.c b/fs/jffs2/nodelist.c
index 007d52f..b5f73ab 100644
--- a/fs/jffs2/nodelist.c
+++ b/fs/jffs2/nodelist.c
@@ -7,7 +7,7 @@
*
* For licensing information, see the file 'LICENCE' in this directory.
*
- * $Id: nodelist.c,v 1.107 2005/08/03 09:26:46 dedekind Exp $
+ * $Id: nodelist.c,v 1.108 2005/08/04 11:39:59 dedekind Exp $
*
*/
@@ -412,7 +412,7 @@ static int check_node_data(struct jffs2_sb_info *c, struct jffs2_tmp_dnode_info
/* Calculate how many bytes were already checked */
ofs = ref_offset(ref) + sizeof(struct jffs2_raw_inode);
- len = ofs - (ofs & (PAGE_CACHE_SIZE - 1));
+ len = ofs & (c->wbuf_pagesize - 1);
len = c->wbuf_pagesize - len;
if (len >= tn->csize) {