diff options
author | Andrea Claudi <aclaudi@redhat.com> | 2019-02-16 16:39:53 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2019-03-01 14:19:04 +0100 |
commit | f25a9b8515a40cdd8cea9d38176d78266f5f941e (patch) | |
tree | de8a54f8228a84259bd7674bed9cd735066a7d6c /net/netfilter/ipvs/ip_vs_ftp.c | |
parent | netfilter: nft_set_hash: remove nft_hash_key() (diff) | |
download | linux-dev-f25a9b8515a40cdd8cea9d38176d78266f5f941e.tar.xz linux-dev-f25a9b8515a40cdd8cea9d38176d78266f5f941e.zip |
ipvs: change some data types from int to bool
Change the data type of the following variables from int to bool
across ipvs code:
- found
- loop
- need_full_dest
- need_full_svc
- payload_csum
Also change the following functions to use bool full_entry param
instead of int:
- ip_vs_genl_parse_dest()
- ip_vs_genl_parse_service()
This patch does not change any functionality but makes the source
code slightly easier to read.
Signed-off-by: Andrea Claudi <aclaudi@redhat.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Acked-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net/netfilter/ipvs/ip_vs_ftp.c')
-rw-r--r-- | net/netfilter/ipvs/ip_vs_ftp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/netfilter/ipvs/ip_vs_ftp.c b/net/netfilter/ipvs/ip_vs_ftp.c index 4398a72edec5..fe69d46ff779 100644 --- a/net/netfilter/ipvs/ip_vs_ftp.c +++ b/net/netfilter/ipvs/ip_vs_ftp.c @@ -124,7 +124,7 @@ static int ip_vs_ftp_get_addrport(char *data, char *data_limit, } s = data + plen; if (skip) { - int found = 0; + bool found = false; for (;; s++) { if (s == data_limit) @@ -136,7 +136,7 @@ static int ip_vs_ftp_get_addrport(char *data, char *data_limit, if (!ext && isdigit(*s)) break; if (*s == skip) - found = 1; + found = true; } else if (*s != skip) { break; } |