All users were logged out of Bugzilla on October 13th, 2018

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

RESOLVED WORKSFORME

Status

()

RESOLVED WORKSFORME
6 years ago
6 years ago

People

(Reporter: dholbert, Unassigned)

Tracking

(Blocks: 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

6 years ago
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
}
(Reporter)

Comment 1

6 years ago
Build log w/ these warnings treated as errors:
 https://tbpl.mozilla.org/php/getParsedLog.php?id=20652593&tree=Try
(Reporter)

Comment 2

6 years ago
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.
(Reporter)

Comment 3

6 years ago
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
Last Resolved: 6 years ago
Depends on: 857863
Resolution: --- → WORKSFORME
(Reporter)

Comment 4

6 years ago
(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.