diff options
author | Mark Wielaard <mjw@redhat.com> | 2016-11-02 13:29:26 +0100 |
---|---|---|
committer | Mark Wielaard <mjw@redhat.com> | 2016-11-10 11:59:00 +0100 |
commit | a3cc8182b2ae05290b0eafa74b70746d7befc0e4 (patch) | |
tree | 7d1f74f9f464b810a95dc7cd78c73930a938924a /src/objdump.c | |
parent | 33ca0e1b9dfb47c6f9836c7fc19d04bd34337767 (diff) | |
download | elfutils-a3cc8182b2ae05290b0eafa74b70746d7befc0e4.tar.gz |
Add GCC7 -Wimplicit-fallthrough support/fixes.
GCC7 will have a new -Wimplicit-fallthrough warning. It did catch one
small buglet in elflint option procession. So it seems useful to enable
to make sure all swatch case fallthroughs are deliberate.
Add configure check to detect whether gcc support -Wimplicit-fallthrough
and enable it. Add fixes and explicit fallthrough comments where necessary.
Signed-off-by: Mark Wielaard <mjw@redhat.com>
Diffstat (limited to 'src/objdump.c')
-rw-r--r-- | src/objdump.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/objdump.c b/src/objdump.c index 1afcd573..f84513ca 100644 --- a/src/objdump.c +++ b/src/objdump.c @@ -234,7 +234,9 @@ parse_opt (int key, char *arg, program_invocation_short_name); exit (EXIT_FAILURE); } - + /* We only use this for checking the number of arguments, we don't + actually want to consume them. */ + /* Fallthrough */ default: return ARGP_ERR_UNKNOWN; } |