Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix napi warnings #14053

Merged
merged 2 commits into from
Jul 5, 2017
Merged

Fix napi warnings #14053

merged 2 commits into from
Jul 5, 2017

Commits on Jul 5, 2017

  1. n-api: use Maybe version of Object::SetPrototype()

    Fixes the following deprecation warning:
    
        ../src/node_api.cc:2020:30: warning: 'bool
        v8::Object::SetPrototype(v8::Local<v8::Value>)' is deprecated: Use
        maybe version [-Wdeprecated-declarations]
           wrapper->SetPrototype(proto);
        ../src/node_api.cc:2021:28: warning: 'bool
        v8::Object::SetPrototype(v8::Local<v8::Value>)' is deprecated: Use
        maybe version [-Wdeprecated-declarations]
           obj->SetPrototype(wrapper);
    
    PR-URL: nodejs#14053
    Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
    Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    bnoordhuis committed Jul 5, 2017
    Configuration menu
    Copy the full SHA
    c9b6d95 View commit details
    Browse the repository at this point in the history
  2. n-api: fix -Wmaybe-uninitialized compiler warning

    Not an actual bug, as far as I can tell, the compiler is simply not
    smart enough to figure out that the offending code path isn't reached
    with an uninitialized value.
    
    PR-URL: nodejs#14053
    Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
    Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    bnoordhuis committed Jul 5, 2017
    Configuration menu
    Copy the full SHA
    e36917b View commit details
    Browse the repository at this point in the history