mirror of https://github.com/lukechilds/node.git
Browse Source
Currently the following compiler warning is generated: 1 warning generated. ../src/udp_wrap.cc:238:12: warning: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Wsign-compare] if (size != args[0].As<Uint32>()->Value()) { ~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 warning generated. This commit changes the check to see that the Uint32 value does not exceed the max int size instead of first casting and then comparing. PR-URL: https://github.com/nodejs/node/pull/15402 Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>canary-base
1 changed files with 2 additions and 2 deletions
Loading…
Reference in new issue