]> Savannah Git Hosting - gnulib.git/commit
long-options: avoid new GCC 7 warning from -Wimplicit-fallthrough
authorJim Meyering <meyering@fb.com>
Wed, 5 Oct 2016 17:43:09 +0000 (10:43 -0700)
committerJim Meyering <meyering@fb.com>
Wed, 5 Oct 2016 17:43:09 +0000 (10:43 -0700)
commitd392d4925dd6649ad11b5885a0602d14069f685c
treec91280638b34df530898009337305cdbd59cd9db
parentd7ccbff42ce581fac951d9ac1579f253e3cbd2e2
long-options: avoid new GCC 7 warning from -Wimplicit-fallthrough

* lib/long-options.c (parse_long_options): Add a break statement
to avoid this new warning/failure:
$ CFLAGS='-O -Werror=implicit-fallthrough' ./gnulib-tool \
  --create-testdir --dir=/t/x --with-tests --test long-options
../../gllib/long-options.c: In function ‘parse_long_options’:
../../gllib/long-options.c:66:12: error: this statement may \
  fall through [-Werror=implicit-fallthrough]
           (*usage_func) (EXIT_SUCCESS);
           ~^~~~~~~~~~~~~~~~~~~~~~~~~~~
ChangeLog
lib/long-options.c