提交 7107944a 编写于 作者: B Blue Swirl

slirp: fix unused return value, spotted by clang

Fix clang errors like:
  CC    slirp/cksum.o
/src/qemu/slirp/cksum.c:78:3: error: expression result unused [-Wunused-value]
                REDUCE;
/src/qemu/slirp/cksum.c:45:66: note: instantiated from:
Signed-off-by: NBlue Swirl <blauwirbel@gmail.com>
上级 156aa898
......@@ -42,7 +42,8 @@
*/
#define ADDCARRY(x) (x > 65535 ? x -= 65535 : x)
#define REDUCE {l_util.l = sum; sum = l_util.s[0] + l_util.s[1]; ADDCARRY(sum);}
#define REDUCE {l_util.l = sum; sum = l_util.s[0] + l_util.s[1]; \
(void)ADDCARRY(sum);}
int cksum(struct mbuf *m, int len)
{
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册