From 85ca97a1cc6baa65715358361799e97a1cf3ca33 Mon Sep 17 00:00:00 2001 From: Yan Burman Date: Wed, 6 Dec 2006 20:40:34 -0800 Subject: [PATCH] --- yaml --- r: 42954 b: refs/heads/master c: 4a08a9f68168e547c2baf100020e9b96cae5fbd1 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/jffs/intrep.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 482de2092615..77d8e3ff5620 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a0172a6dd906cf813cd56aeb133a85abf9a36c8e +refs/heads/master: 4a08a9f68168e547c2baf100020e9b96cae5fbd1 diff --git a/trunk/fs/jffs/intrep.c b/trunk/fs/jffs/intrep.c index 478a74e2e9d5..d0e783f199ea 100644 --- a/trunk/fs/jffs/intrep.c +++ b/trunk/fs/jffs/intrep.c @@ -592,7 +592,7 @@ jffs_add_virtual_root(struct jffs_control *c) D2(printk("jffs_add_virtual_root(): " "Creating a virtual root directory.\n")); - if (!(root = kmalloc(sizeof(struct jffs_file), GFP_KERNEL))) { + if (!(root = kzalloc(sizeof(struct jffs_file), GFP_KERNEL))) { return -ENOMEM; } no_jffs_file++; @@ -604,7 +604,6 @@ jffs_add_virtual_root(struct jffs_control *c) DJM(no_jffs_node++); memset(node, 0, sizeof(struct jffs_node)); node->ino = JFFS_MIN_INO; - memset(root, 0, sizeof(struct jffs_file)); root->ino = JFFS_MIN_INO; root->mode = S_IFDIR | S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH;