[core] Avoid calling virtual GeometryTile::cancel() on dtor

warning: Call to virtual function during destruction will not dispatch
to derived class [clang-analyzer-optin.cplusplus.VirtualCall]
This commit is contained in:
Bruno de Oliveira Abinader
2017-05-10 18:14:35 +03:00
parent 5dfb315b2f
commit 5d89f6cd92
2 changed files with 7 additions and 1 deletions

View File

@@ -47,10 +47,14 @@ GeometryTile::GeometryTile(const OverscaledTileID& id_,
GeometryTile::~GeometryTile() {
glyphAtlas.removeGlyphs(*this);
spriteAtlas.removeRequestor(*this);
cancel();
markObsolete();
}
void GeometryTile::cancel() {
markObsolete();
}
void GeometryTile::markObsolete() {
obsolete = true;
}

View File

@@ -87,6 +87,8 @@ protected:
}
private:
void markObsolete();
const std::string sourceID;
style::Style& style;