mirror of
https://codeberg.org/anoncontributorxmr/monero.git
synced 2024-11-22 23:42:24 +00:00
fix: error: -Werror=misleading-indentation
Compilation of bitmonero on Arch with gcc 6.1 results in the following error: /home/mwo/bitmonero/tests/unit_tests/hardfork.cpp: In member function ‘virtual void TestDB::set_hard_fork_version(uint64_t, uint8_t)’: /home/mwo/bitmonero/tests/unit_tests/hardfork.cpp:132:5: error: this ‘if’ clause does not guard... [-Werror=misleading-indentation] if (versions.size() <= height) versions.resize(height+1); versions[height] = version; This can be fixed by simply unfolding this line into three lines.
This commit is contained in:
parent
c2d7300d2e
commit
de030d99a5
1 changed files with 3 additions and 1 deletions
|
@ -129,7 +129,9 @@ public:
|
|||
return starting_height[version];
|
||||
}
|
||||
virtual void set_hard_fork_version(uint64_t height, uint8_t version) {
|
||||
if (versions.size() <= height) versions.resize(height+1); versions[height] = version;
|
||||
if (versions.size() <= height)
|
||||
versions.resize(height+1);
|
||||
versions[height] = version;
|
||||
}
|
||||
virtual uint8_t get_hard_fork_version(uint64_t height) const {
|
||||
return versions[height];
|
||||
|
|
Loading…
Reference in a new issue