Closed Bug 1257411 Opened 7 years ago Closed 2 years ago
_services .cc(282): warning C4311: 'reinterpret _cast': pointer truncation from 'LPOVERLAPPED' to 'DWORD'
The C4311 warning is being enabled in bug 1124033. When it is enabled, 2 warnings occur in broker_services.cc when building with VS2015u1. These warnings fail the build because of warnings as errors and therefore block the switch to Visual Studio 2015. security/sandbox/chromium/sandbox/win/src/broker_services.cc(282): warning C4311: 'reinterpret_cast': pointer truncation from 'LPOVERLAPPED' to 'DWORD' security/sandbox/chromium/sandbox/win/src/broker_services.cc(312): warning C4311: 'reinterpret_cast': pointer truncation from 'LPOVERLAPPED' to 'DWORD'
I've just checked and it looks like these have been fixed upstream: https://chromium.googlesource.com/chromium/src/+/359cb535d023f8c83f7b6a796bc43a30f4594ad7 I was trying to take a new version of the upstream sandboxing code in bug 1228604, but was blocked because we don't have the latest VS2013 updates on the build servers. I haven't had time to see if we could work around that, so was waiting for the TaskCluster switch-over, which would apparently be using the latest. Hopefully if we move to VS2015 first, then that will solve my problems and I can update, which will mean we can get rid of these. When this switch happens, would all builds be using VS2015?
I'm trying to move mozilla-central to VS2015 this release cycle. All Windows builds using Visual Studio would be using VS2015u1. That will ride the trains. As for this bug, I see 2 options: 1) cherry pick the upstream fix 2) Disable C4311 and undisable it once you import the latest upstream code [after the VS2015 transition occurs]. Also, bug 1256490, bug 1256499, bug 1256484, and bug 1257036 all hide VS2015 warnings in security/. We shouldn't lose track of undoing the workarounds related to patched upstream code.
OK thanks, I think we might as well wait until we take the full update. I'll see if we can remove any of the warning suppressions when I do that, including these latest ones.
Bug 1124033 landed the -wd4311 addition that was initially in this bug. Morphing this bug to track removing that flag from CXXFLAGS in security/sandbox/staticruntime/moz.build.
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.