diff options
author | Stephen Hemminger <stephen@networkplumber.org> | 2023-06-28 16:32:22 -0700 |
---|---|---|
committer | Stephen Hemminger <stephen@networkplumber.org> | 2023-06-28 16:32:22 -0700 |
commit | 2b41725d2a46c22ee9c55bc1725e926801f20d57 (patch) | |
tree | 37eb021781ad3f90f934f92a228600eabe0ee7b7 | |
parent | 9ef3210bc7dfeaf660b484a1a5a4d591dddf6076 (diff) | |
download | iproute2-2b41725d2a46c22ee9c55bc1725e926801f20d57.tar.gz |
fix fallthrough warnings
In lib/utils.c comment for fallthrough was in wrong place
and one was missing in xfrm_state.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
-rw-r--r-- | ip/xfrm_state.c | 1 | ||||
-rw-r--r-- | lib/utils.c | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/ip/xfrm_state.c b/ip/xfrm_state.c index a7b3d0e14..9be65b2f8 100644 --- a/ip/xfrm_state.c +++ b/ip/xfrm_state.c @@ -660,6 +660,7 @@ static int xfrm_state_modify(int cmd, unsigned int flags, int argc, char **argv) case XFRM_MODE_BEET: if (req.xsinfo.id.proto == IPPROTO_ESP) break; + /* fallthrough */ default: fprintf(stderr, "MODE value is invalid with XFRM-PROTO value \"%s\"\n", strxf_xfrmproto(req.xsinfo.id.proto)); diff --git a/lib/utils.c b/lib/utils.c index 01f3a5f7e..b1f273054 100644 --- a/lib/utils.c +++ b/lib/utils.c @@ -985,9 +985,8 @@ const char *rt_addr_n2a_r(int af, int len, return inet_ntop(AF_INET6, &sa->sin6.sin6_addr, buf, buflen); } - - /* fallthrough */ } + /* fallthrough */ default: return "???"; } |