projects
/
haproxy-2.5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d69d65a
)
CLEANUP: sock: Wrap `accept4_broken = 1` into additional parenthesis
author
Tim Duesterhus
<tim@bastelstu.be>
Sat, 20 Nov 2021 13:39:47 +0000
(14:39 +0100)
committer
Willy Tarreau
<w@1wt.eu>
Sat, 20 Nov 2021 13:52:01 +0000
(14:52 +0100)
This makes it clear to static analysis tools that this assignment is
intentional and not a mistyped comparison.
src/sock.c
patch
|
blob
|
history
diff --git
a/src/sock.c
b/src/sock.c
index
e3d4a6e
..
f11c5b0
100644
(file)
--- a/
src/sock.c
+++ b/
src/sock.c
@@
-74,7
+74,7
@@
struct connection *sock_accept_conn(struct listener *l, int *status)
(((cfd = accept4(l->rx.fd, (struct sockaddr*)addr, &laddr,
SOCK_NONBLOCK | (master ? SOCK_CLOEXEC : 0))) == -1) &&
(errno == ENOSYS || errno == EINVAL || errno == EBADF) &&
- (accept4_broken = 1)))
+ ((accept4_broken = 1))))
#endif
{
laddr = sizeof(*conn->src);