浏览代码

net/net.c: cosmetic: do not use assignment in if condition

This removes the following checkpatch issue:
 - ERROR: do not use assignment in if condition

Signed-off-by: Luca Ceresoli <luca.ceresoli@comelit.it>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Ben Warren <biggerbadderben@gmail.com>
Luca Ceresoli 14 年之前
父节点
当前提交
ccb9ebefbe
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      net/net.c

+ 2 - 1
net/net.c

@@ -1616,7 +1616,8 @@ NetReceive(volatile uchar *inpkt, int len)
 		 * a fragment, and either the complete packet or NULL if
 		 * it is a fragment (if !CONFIG_IP_DEFRAG, it returns NULL)
 		 */
-		if (!(ip = NetDefragment(ip, &len)))
+		ip = NetDefragment(ip, &len);
+		if (!ip)
 			return;
 		/*
 		 * watch for ICMP host redirects