Skip to contentSkip to conversation

fs/isofs/namei.c: fix warnings of uninitialized variables

PATCH In review Petri T. Koistinen 2 participants 2 messages May 1, 2006 – May 2, 2006 Isofs filesystem

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fs/isofs/namei.c: fix warnings of uninitialized variables

From: Petri T. Koistinen <[email protected]>

Remove warnings by initializing uninitialized variables.

---
 fs/isofs/namei.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

---

fs/isofs/namei.c +1 -1
index e7ba0c3..e0d6531 100644
@@ -159,7 +159,7 @@ isofs_find_entry(struct inode *dir, stru
 struct dentry *isofs_lookup(struct inode * dir, struct dentry * dentry, struct nameidata *nd)
 {
 	int found;
-	unsigned long block, offset;
+	unsigned long block = 0, offset = 0;
 	struct inode *inode;
 	struct page *page;
 
#1 lore raw
Quoted 15 lines · Petri T. Koistinen

From: Petri T. Koistinen <[email protected]>

Remove warnings by initializing uninitialized variables.

---
 fs/isofs/namei.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

---

fs/isofs/namei.c +0 -0
index e7ba0c3..e0d6531 100644

fs/isofs/namei.c isofs_find_entry(struct inode *dir, stru · line 162

Quoted 5 lines
fs/isofs/namei.c +1 -1
@@ -159,7 +159,7 @@ isofs_find_entry(struct inode *dir, stru
 struct dentry *isofs_lookup(struct inode * dir, struct dentry * dentry, struct nameidata *nd)
 {
        int found;
-       unsigned long block, offset;
+       unsigned long block = 0, offset = 0;

NAK. Both are initialized by isofs_find_entry() before being used.

Pekka