Skip to content

Commit

Permalink
conntrack: Fix Windows build due to ternary syntax extension.
Browse files Browse the repository at this point in the history
In the cited commit a ternary using syntax extension slipped in.

The extension allows omitting the second operand and it is not
supported by MSVC resulting in a build failure.

Fix it by simply specifying the second operand.

Fixes: b57c1da ("conntrack: Use a per zone default limit.")
Reported-by: Ilya Maximets <[email protected]>
[Paolo: added commit message]
Co-authored-by: Paolo Valerio <[email protected]>
Signed-off-by: Paolo Valerio <[email protected]>
Signed-off-by: Aaron Conole <[email protected]>
Signed-off-by: Eelco Chaudron <[email protected]>
  • Loading branch information
2 people authored and chaudron committed Oct 14, 2024
1 parent d1430f3 commit 4c5c1aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/conntrack.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ zone_limit_get_limit(struct conntrack *ct, struct conntrack_zone_limit *czl)

if (limit == ZONE_LIMIT_CONN_DEFAULT) {
atomic_read_relaxed(&ct->default_zone_limit, &limit);
limit = limit ? : -1;
limit = limit ? limit : -1;
}

return limit;
Expand Down

0 comments on commit 4c5c1aa

Please sign in to comment.