Shared/Metric: Fix crash on shutdown

Fix crash on shutdown with metrics enabled but InfluxDB stopping before worldserver
This commit is contained in:
jackpoz
2017-12-17 14:35:18 +01:00
parent 3bb166dd5c
commit 45b2bcfaf2
3 changed files with 6 additions and 5 deletions

View File

@@ -232,7 +232,7 @@ extern int main(int argc, char** argv)
std::shared_ptr<void> sMetricHandle(nullptr, [](void*)
{
TC_METRIC_EVENT("events", "Worldserver shutdown", "");
sMetric->ForceSend();
sMetric->Unload();
});
sScriptMgr->SetScriptLoader(AddScripts);