mirror of
https://git.tukaani.org/xz.git
synced 2024-04-04 12:36:23 +02:00
Fix or hide warnings from GCC 7's -Wimplicit-fallthrough.
This commit is contained in:
parent
0b0e1e6803
commit
94e3f986aa
2 changed files with 8 additions and 0 deletions
|
@ -16,6 +16,12 @@
|
||||||
#include "lzma_decoder.h"
|
#include "lzma_decoder.h"
|
||||||
#include "range_decoder.h"
|
#include "range_decoder.h"
|
||||||
|
|
||||||
|
// The macros unroll loops with switch statements.
|
||||||
|
// Silence warnings about missing fall-through comments.
|
||||||
|
#if TUKLIB_GNUC_REQ(7, 0)
|
||||||
|
# pragma GCC diagnostic ignored "-Wimplicit-fallthrough"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_SMALL
|
#ifdef HAVE_SMALL
|
||||||
|
|
||||||
|
|
|
@ -318,6 +318,8 @@ parse_block_header(file_pair *pair, const lzma_index_iter *iter,
|
||||||
// If the above fails, the file is corrupt so
|
// If the above fails, the file is corrupt so
|
||||||
// LZMA_DATA_ERROR is a good error code.
|
// LZMA_DATA_ERROR is a good error code.
|
||||||
|
|
||||||
|
// Fall through
|
||||||
|
|
||||||
case LZMA_DATA_ERROR:
|
case LZMA_DATA_ERROR:
|
||||||
// Free the memory allocated by lzma_block_header_decode().
|
// Free the memory allocated by lzma_block_header_decode().
|
||||||
for (size_t i = 0; filters[i].id != LZMA_VLI_UNKNOWN; ++i)
|
for (size_t i = 0; filters[i].id != LZMA_VLI_UNKNOWN; ++i)
|
||||||
|
|
Loading…
Reference in a new issue