From 9a1b2fbdc9f319aaf57a79f8e6ce7d5e6a3ecaa6 Mon Sep 17 00:00:00 2001 From: Daniel Borkmann Date: Tue, 4 Jun 2013 00:52:09 +0200 Subject: corking: use bool instead of int We have a boolen condition, so use bool instead of doing stupid things with ints. Signed-off-by: Daniel Borkmann --- corking.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'corking.c') diff --git a/corking.c b/corking.c index a6e0f84..ce10324 100644 --- a/corking.c +++ b/corking.c @@ -49,17 +49,17 @@ void set_tcp_uncork(int fd) panic("Cannot uncork TCP socket!\n"); } -void set_sock_cork(int fd, int udp) +void set_sock_cork(int fd, bool is_udp) { - if (!!udp) + if (is_udp) set_udp_cork(fd); else set_tcp_cork(fd); } -void set_sock_uncork(int fd, int udp) +void set_sock_uncork(int fd, bool is_udp) { - if (!!udp) + if (is_udp) set_udp_uncork(fd); else set_tcp_uncork(fd); -- cgit v1.2.3-54-g00ecf