fix: initialize local variable to prevent c4701 warning on windows arm#1122
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1122 +/- ##
==========================================
- Coverage 82.68% 82.64% -0.04%
==========================================
Files 53 53
Lines 7930 7930
Branches 1240 1240
==========================================
- Hits 6557 6554 -3
- Misses 1263 1264 +1
- Partials 110 112 +2 |
supervacuus
left a comment
There was a problem hiding this comment.
This is a false positive since we only write to the event_id. I am okay with initializing it; if the value is already initialized, it will behave the same since it is a pure output parameter.
|
@jkosberg, I have bad news: #1138 accidentally removed that initialization in its first commit (probably from an old branch) and this was never rectified and thus got released with If you can wait, I recommend not upgrading to |
getsentry#1122) * Prevent c4701 warning on windows arm * comment that init has no semantic meaning --------- Co-authored-by: Mischan Toosarani-Hausberger <[email protected]>
When trying to build the sentry toolchain on windows arm, I am seeing the following warning:
When we compile the sentry code, we enable warnings as errors globally and hit this warning which fails our builds unless we disable it. It looks like a simple fix. It appears on arm, a separate optimization path is hit and spits out this warning, but it doesn't create the same warning in an x86_64 build. Would like to just get this updated as I think it is also more "correct" this way as well!
#skip-changelog