public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] ubifs.c: BUG: Error following links
@ 2010-12-02 14:02 Ricardo Ribalda Delgado
  2010-12-03 15:53 ` Stefan Roese
  0 siblings, 1 reply; 2+ messages in thread
From: Ricardo Ribalda Delgado @ 2010-12-02 14:02 UTC (permalink / raw)
  To: u-boot

The link_name variable is declared inside the if block and it is used
outside it through the name pointer.

Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
 fs/ubifs/ubifs.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fs/ubifs/ubifs.c b/fs/ubifs/ubifs.c
index 0f8128c..2bad027 100644
--- a/fs/ubifs/ubifs.c
+++ b/fs/ubifs/ubifs.c
@@ -386,6 +386,7 @@ static unsigned long ubifs_findfile(struct super_block *sb, char *filename)
 	unsigned long root_inum = 1;
 	unsigned long inum;
 	int symlink_count = 0; /* Don't allow symlink recursion */
+	char link_name[64];
 
 	strcpy(fpath, filename);
 
@@ -422,7 +423,6 @@ static unsigned long ubifs_findfile(struct super_block *sb, char *filename)
 		ui = ubifs_inode(inode);
 
 		if ((inode->i_mode & S_IFMT) == S_IFLNK) {
-			char link_name[64];
 			char buf[128];
 
 			/* We have some sort of symlink recursion, bail out */
-- 
1.7.2.3

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-12-03 15:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-02 14:02 [U-Boot] [PATCH] ubifs.c: BUG: Error following links Ricardo Ribalda Delgado
2010-12-03 15:53 ` Stefan Roese

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox