Fix some warnings

This commit is contained in:
Erica Fischer
2024-01-24 11:41:59 -08:00
parent 6da318b807
commit f2ced94e30
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -166,7 +166,7 @@ struct entryv3 {
}
};
struct {
static struct {
bool operator()(entryv3 a, entryv3 b) const {
return a.tile_id < b.tile_id;
}
@@ -388,7 +388,7 @@ inline uint64_t zxy_to_tileid(uint8_t z, uint32_t x, uint32_t y) {
if (z > 31) {
throw std::overflow_error("tile zoom exceeds 64-bit limit");
}
if (x > (1 << z) - 1 || y > (1 << z) - 1) {
if (x > (1U << z) - 1 || y > (1U << z) - 1) {
throw std::overflow_error("tile x/y outside zoom level bounds");
}
uint64_t acc = 0;
+2 -2
View File
@@ -688,8 +688,8 @@ struct tileset_reader {
perror("pthread_mutex_lock");
}
std::function<mvt_tile(zxy)> getter = [&](zxy tile) {
return get_tile(tile);
std::function<mvt_tile(zxy)> getter = [&](zxy tileno) {
return get_tile(tileno);
};
mvt_tile source = cache.get(parent_tile, getter);