FIRE-3925: Paket loss in "About" floater will show 1 after reaching 1,000,000

Ansariel 2014-01-19 04:31:41 +01:00
parent 465c4a2454
commit 41b6aaa395
1 changed files with 5 additions and 1 deletions

View File

@ -354,7 +354,11 @@ LLSD LLFloaterAbout::getInfo()
if (gPacketsIn > 0)
{
info["PACKETS_LOST"] = LLViewerStats::getInstance()->mPacketsLostStat.getCurrent();
info["PACKETS_IN"] = F32(gPacketsIn);
// <FS:Ansariel> FIRE-3925: Formatting fails when reaching 1,000,000;
// Use S32 since it will be used in LLStringUtil::formatNumber anyway.
//info["PACKETS_IN"] = F32(gPacketsIn);
info["PACKETS_IN"] = S32(gPacketsIn);
// </FS:Ansariel>
info["PACKETS_PCT"] = 100.f*info["PACKETS_LOST"].asReal() / info["PACKETS_IN"].asReal();
}