diff options
author | Alex Wang <alexw@nicira.com> | 2013-07-22 09:19:57 -0700 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2013-07-22 12:47:59 -0700 |
commit | 33e191a01b2c5aad1e97c109e66dec4b4d280ef6 (patch) | |
tree | 2bd6472602bc7f2de9a90c2108435d0252ab7a09 /lib/hindex.h | |
parent | 55d2690646769467b6d26ad55516ff6eeb12869d (diff) |
clang: Fix the "expression result unused" warning.
This commit makes macro function "ASSIGN_CONTAINER()" evaluates
to "(void)0". This is to avoid the 'clang' warning: "expression
result unused", since most of time, the final evaluated value
is not used.
Signed-off-by: Alex Wang <alexw@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'lib/hindex.h')
-rw-r--r-- | lib/hindex.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/hindex.h b/lib/hindex.h index ce46596a..fb6b6d2b 100644 --- a/lib/hindex.h +++ b/lib/hindex.h @@ -147,7 +147,7 @@ struct hindex_node *hindex_node_with_hash(const struct hindex *, size_t hash); #define HINDEX_FOR_EACH_SAFE(NODE, NEXT, MEMBER, HINDEX) \ for (ASSIGN_CONTAINER(NODE, hindex_first(HINDEX), MEMBER); \ (NODE != OBJECT_CONTAINING(NULL, NODE, MEMBER) \ - ? ASSIGN_CONTAINER(NEXT, hindex_next(HINDEX, &(NODE)->MEMBER), MEMBER) \ + ? ASSIGN_CONTAINER(NEXT, hindex_next(HINDEX, &(NODE)->MEMBER), MEMBER), 1 \ : 0); \ (NODE) = (NEXT)) |