Fix MSVC C4244 build warnings (for type conversions) in Telemetry.cpp

RESOLVED WORKSFORME

Status

()

defect
RESOLVED WORKSFORME
7 years ago
7 years ago

People

(Reporter: dholbert, Unassigned)

Tracking

(Blocks 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

MSVC has these build warnings for Telemetry.cpp:
{
e:/builds/moz2_slave/try-w32-d-00000000000000000000/build/toolkit/components/telemetry/Telemetry.cpp(547) : warning C4244: 'argument' : conversion from 'int64_t' to 'double', possible loss of data

e:/builds/moz2_slave/try-w32-d-00000000000000000000/build/toolkit/components/telemetry/Telemetry.cpp(815) : warning C4244: 'argument' : conversion from 'int64_t' to 'uint32_t', possible loss of data

e:/builds/moz2_slave/try-w32-d-00000000000000000000/build/toolkit/components/telemetry/Telemetry.cpp(2135) : warning C4244: 'initializing' : conversion from 'double' to 'uint32_t', possible loss of data

e:/builds/moz2_slave/try-w32-d-00000000000000000000/build/toolkit/components/telemetry/Telemetry.cpp(2393) : warning C4244: 'argument' : conversion from 'int64_t' to 'uint32_t', possible loss of data
}
Build log w/ these warnings treated as errors:
 https://tbpl.mozilla.org/php/getParsedLog.php?id=20652593&tree=Try
Note: bug 851183 just landed, marking this directory as FAIL_ON_WARNINGS for non-MSVC compilers.

When the warnings described in this bug here are fixed, we can remove the "_MSC_VER" check (exempting MSVC) there.
We've actually disabled warning C4244 now, in bug 857863, so while the underlying issue presumably remains, the "causes warnings" aspect is WORKSFORME.
Status: NEW → RESOLVED
Closed: 7 years ago
Depends on: 857863
Resolution: --- → WORKSFORME
(And the _MSC_VER check noted in comment 2 will be going away in bug 858224.)
You need to log in before you can comment on or make changes to this bug.