1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

Fix -Wtype-limits

This commit is contained in:
Alexey Antipovsky
2020-11-10 18:23:21 +00:00
parent f4a6294c95
commit 0e29b0b0f9
11 changed files with 75 additions and 19 deletions

View File

@ -29,6 +29,7 @@
#define BOOST_SPIRIT_THREADSAFE
#include <boost/property_tree/json_parser.hpp>
#include <iostream>
#include "checks.h"
#define max(x, y) (x > y ? x : y)
#define min(x, y) (x < y ? x : y)
@ -823,7 +824,7 @@ int IOCoordinator::_truncate(const bf::path &bfpath, size_t newSize, ScopedFileL
else
{
meta.updateEntryLength(objects[0].offset, newSize - objects[0].offset);
assert(objects[0].offset >= 0 && objectSize > (newSize - objects[0].offset));
assert(utils::is_nonnegative(objects[0].offset) && objectSize > (newSize - objects[0].offset));
}
for (uint i = 1; i < objects.size(); i++)
meta.removeEntry(objects[i].offset);