Skip to content

Conversation

@mhdawson
Copy link
Member

  • address coverity unitialized variable warning

Signed-off-by: Michael Dawson [email protected]

@nodejs-github-bot
Copy link
Collaborator

Review requested:

  • @nodejs/node-api

@nodejs-github-botnodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. needs-ci PRs that need a full CI run. node-api Issues and PRs related to the Node-API. labels Nov 21, 2022
@mhdawson
Copy link
MemberAuthor

mhdawson commented Nov 21, 2022

This is the report. I think technically it may be a false positive, but initializing the variable seems ok as well, so PR does that versus marking as false positive.

/ Create a new napi_env forthis specific module. 634 napi_env env = v8impl::NewEnv(context, module_filename); 6353. var_decl: Declaring variable _exports without initializer. 636 napi_value _exports; 637 env->CallIntoModule([&](napi_env env){638 _exports = init(env, v8impl::JsValueFromV8LocalValue(exports)); 639 }); 640641// If register function returned a non-null exports object different from642// the exports object we passed it, set that as the "exports" property of643// the module. CID 276441 (#1 of 1): Uninitialized pointer read (UNINIT) 4. uninit_use: Using uninitialized value _exports. 644 if (_exports != nullptr && 645 _exports != v8impl::JsValueFromV8LocalValue(exports)){646 napi_value _module = v8impl::JsValueFromV8LocalValue(module); 647napi_set_named_property(env, _module, "exports", _exports); 648 }

- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]>
@daeyeondaeyeon added author ready PRs that have at least one approval, no pending requests for changes, and a CI started. request-ci Add this label to start a Jenkins CI on a PR. labels Nov 22, 2022
@TrottTrott changed the title doc: address coverity warningnode-api: address coverity warningNov 22, 2022
@github-actionsgithub-actionsbot removed the request-ci Add this label to start a Jenkins CI on a PR. label Nov 22, 2022
@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot
Copy link
Collaborator

mhdawson added a commit that referenced this pull request Nov 24, 2022
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
@mhdawson
Copy link
MemberAuthor

Landed in 0bbef56

ruyadorno pushed a commit that referenced this pull request Nov 24, 2022
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
@ruyadornoruyadorno mentioned this pull request Nov 24, 2022
ErickWendel pushed a commit to ErickWendel/node that referenced this pull request Nov 30, 2022
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: nodejs#45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
danielleadams pushed a commit that referenced this pull request Dec 30, 2022
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
danielleadams pushed a commit that referenced this pull request Dec 30, 2022
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
danielleadams pushed a commit that referenced this pull request Jan 3, 2023
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
danielleadams pushed a commit that referenced this pull request Jan 4, 2023
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
danielleadams pushed a commit that referenced this pull request Jan 5, 2023
- address coverity unitialized variable warning Signed-off-by: Michael Dawson <[email protected]> PR-URL: #45563 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Daeyeon Jeong <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author readyPRs that have at least one approval, no pending requests for changes, and a CI started.c++Issues and PRs that require attention from people who are familiar with C++.needs-ciPRs that need a full CI run.node-apiIssues and PRs related to the Node-API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants

@mhdawson@nodejs-github-bot@Trott@lpinca@cjihrig@richardlau@daeyeon@legendecas