diff options
author | xiphon <xiphon@protonmail.com> | 2018-11-19 22:36:10 +0000 |
---|---|---|
committer | xiphon <xiphon@protonmail.com> | 2018-11-19 22:36:10 +0000 |
commit | fc99f177f3bc29322fc93839e4f238c7fba9a64f (patch) | |
tree | d1bd474716fdacf66b0dd1565896b55341a84804 | |
parent | Merge pull request #4842 (diff) | |
download | monero-fc99f177f3bc29322fc93839e4f238c7fba9a64f.tar.xz |
lmdb: fix gcc 7.3.0 'implicit-fallthrough' warning
-rw-r--r-- | src/blockchain_db/lmdb/db_lmdb.cpp | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/blockchain_db/lmdb/db_lmdb.cpp b/src/blockchain_db/lmdb/db_lmdb.cpp index ea3638a85..622278784 100644 --- a/src/blockchain_db/lmdb/db_lmdb.cpp +++ b/src/blockchain_db/lmdb/db_lmdb.cpp @@ -4358,16 +4358,12 @@ void BlockchainLMDB::migrate_2_3() void BlockchainLMDB::migrate(const uint32_t oldversion) { - switch(oldversion) { - case 0: - migrate_0_1(); /* FALLTHRU */ - case 1: - migrate_1_2(); /* FALLTHRU */ - case 2: - migrate_2_3(); /* FALLTHRU */ - default: - ; - } + if (oldversion < 1) + migrate_0_1(); + if (oldversion < 2) + migrate_1_2(); + if (oldversion < 3) + migrate_2_3(); } } // namespace cryptonote |