]> git.sur5r.net Git - u-boot/commitdiff
jffs2:jffs2_1pass.c: remove double braces
authorJeroen Hofstee <jeroen@myspectrum.nl>
Tue, 10 Jun 2014 22:40:25 +0000 (00:40 +0200)
committerTom Rini <trini@ti.com>
Wed, 11 Jun 2014 20:27:06 +0000 (16:27 -0400)
Clang interpretes an if condition likeĀ  "if ((a = b) == NULL)
as it tries to assign a value in a statement. Hence if you do
"if ((something)) it warns you that you might be confused.
Hence drop the double braces for plane if statements.

Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
fs/jffs2/jffs2_1pass.c

index 3fb5db383ec9206fba37f5f4039f635b30c1cce0..b1d647021928897855166f34c421f5aac680c491 100644 (file)
@@ -724,7 +724,7 @@ jffs2_1pass_read_inode(struct b_lists *pL, u32 inode, char *dest)
        for (b = pL->frag.listHead; b != NULL; b = b->next) {
                jNode = (struct jffs2_raw_inode *) get_node_mem(b->offset,
                                                                pL->readbuf);
-               if ((inode == jNode->ino)) {
+               if (inode == jNode->ino) {
 #if 0
                        putLabeledWord("\r\n\r\nread_inode: totlen = ", jNode->totlen);
                        putLabeledWord("read_inode: inode = ", jNode->ino);