diff options
author | RamanandPatil <ramanand.patil@gmail.com> | 2020-03-02 14:33:55 +0300 |
---|---|---|
committer | Gireesh Punathil <gpunathi@in.ibm.com> | 2020-03-11 08:33:52 +0300 |
commit | d5674fd482249865abb24d3cbc39215d411cf444 (patch) | |
tree | c65a74b1c75e72b2bd0f4b6159f23a75f38479ee /src | |
parent | c1b2f6afbe03841a6f0ca5fa363ceb5bcdcfe638 (diff) |
src: elevate v8 namespace
PR-URL: https://github.com/nodejs/node/pull/32041
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'src')
-rw-r--r-- | src/cares_wrap.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/cares_wrap.cc b/src/cares_wrap.cc index 8abf662caa3..71d8f8569ba 100644 --- a/src/cares_wrap.cc +++ b/src/cares_wrap.cc @@ -64,6 +64,7 @@ using v8::FunctionTemplate; using v8::HandleScope; using v8::Int32; using v8::Integer; +using v8::Isolate; using v8::Local; using v8::Null; using v8::Object; @@ -1917,7 +1918,7 @@ int ParseIP(const char* ip, ParseIPResult* result = nullptr) { } void CanonicalizeIP(const FunctionCallbackInfo<Value>& args) { - v8::Isolate* isolate = args.GetIsolate(); + Isolate* isolate = args.GetIsolate(); node::Utf8Value ip(isolate, args[0]); ParseIPResult result; @@ -1927,7 +1928,7 @@ void CanonicalizeIP(const FunctionCallbackInfo<Value>& args) { char canonical_ip[INET6_ADDRSTRLEN]; const int af = (rc == 4 ? AF_INET : AF_INET6); CHECK_EQ(0, uv_inet_ntop(af, &result, canonical_ip, sizeof(canonical_ip))); - v8::Local<String> val = String::NewFromUtf8(isolate, canonical_ip, + Local<String> val = String::NewFromUtf8(isolate, canonical_ip, v8::NewStringType::kNormal).ToLocalChecked(); args.GetReturnValue().Set(val); } |