Skip to contentSkip to conversation

post: remove redundant condition

PATCH New Heinrich Schuchardt 3 participants 3 messages Aug 3, 2020 – Oct 24, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 post: remove redundant condition

(A && A == 0x20) is only true for (A == 0x20).

---
 post/post.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
post/post.c +1 -1
index 6687e0b75c..0f1fe8d905 100644
@@ -189,7 +189,7 @@ static void post_get_env_flags(int *test_flags)
 		last = 0;
 		name = list;
 		while (!last) {
-			while (*name && *name == ' ')
+			while (*name == ' ')
 				name++;
 			if (*name == 0)
 				break;

--
2.27.0

#2 lore raw

PATCH 1/1 post: remove redundant condition

In reply to Heinrich Schuchardt
Quoted 4 lines · Heinrich Schuchardt

(A && A == 0x20) is only true for (A == 0x20).

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20201024/c7e22ac3/attachment.sig>