Skip to content

Commit

Permalink
src: make model counter in GetCPUInfo() unsigned
Browse files Browse the repository at this point in the history
This fixes a compiler warning about comparing against
the (unsigned) `NODE_PUSH_VAL_TO_ARRAY_MAX` constant.

PR-URL: #23880
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Sam Roberts <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Eugene Ostroukhov <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Matheus Marchini <[email protected]>
  • Loading branch information
addaleax committed Oct 28, 2018
1 parent 1ba10db commit b0089a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/node_os.cc
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ static void GetCPUInfo(const FunctionCallbackInfo<Value>& args) {
Local<Array> cpus = args[2].As<Array>();

Local<Value> model_argv[NODE_PUSH_VAL_TO_ARRAY_MAX];
int model_idx = 0;
unsigned int model_idx = 0;

for (i = 0, field_idx = 0; i < count; i++) {
uv_cpu_info_t* ci = cpu_infos + i;
Expand Down

0 comments on commit b0089a5

Please sign in to comment.