Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUjjwal Sharma <usharma1998@gmail.com>2018-08-29 17:12:36 +0300
committerMichaël Zasso <targos@protonmail.com>2018-09-05 14:42:38 +0300
commitf464ac3c74ca2b2411c578b4dcb52838f569e9fa (patch)
treead733001a2528375cc3fd202a54c80ea8dfbab9c /src/udp_wrap.cc
parent31ca5dc75a0d76d4aeee174e70e335e4ea7428ac (diff)
src: remove calls to deprecated v8 functions (IntegerValue)
Remove all calls to deprecated v8 functions (here: Value::IntegerValue) inside the code (src directory only). Co-authored-by: Michaël Zasso <targos@protonmail.com> PR-URL: https://github.com/nodejs/node/pull/22129 Reviewed-By: Anna Henningsen <anna@addaleax.net>
Diffstat (limited to 'src/udp_wrap.cc')
-rw-r--r--src/udp_wrap.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/udp_wrap.cc b/src/udp_wrap.cc
index c7ca7fc44d6..8005eeb9ff7 100644
--- a/src/udp_wrap.cc
+++ b/src/udp_wrap.cc
@@ -215,7 +215,8 @@ void UDPWrap::Open(const FunctionCallbackInfo<Value>& args) {
ASSIGN_OR_RETURN_UNWRAP(&wrap,
args.Holder(),
args.GetReturnValue().Set(UV_EBADF));
- int fd = static_cast<int>(args[0]->IntegerValue());
+ CHECK(args[0]->IsNumber());
+ int fd = static_cast<int>(args[0].As<Integer>()->Value());
int err = uv_udp_open(&wrap->handle_, fd);
args.GetReturnValue().Set(err);