DescriptionPost fix of CL "declare a variable before using it"
PVS-Studio pointed out that an uninitialized variable 'limit' is used to
initialize itself, which may cause undefined behavior. Other calls to
StringToSizeT() don't have this issue.
After my landing crrev.com/2724153004 for the fix, the declaration and
assignment of variable |limit| are separate. If somebody adds code
between them, there will be a non-trivial interval of |limit| having an
undefined value.
This CL fixed this by initializing |limit| right after its declaration.
BUG=697659
Review-Url: https://codereview.chromium.org/2732913004
Cr-Commit-Position: refs/heads/master@{#454950}
Committed: https://chromium.googlesource.com/chromium/src/+/ed17a3d795edc5af91cd6074a7c299425b1fe9d7
Patch Set 1 #
Messages
Total messages: 15 (11 generated)
|