From fd8dfdfc54e2af0749663e9e0c3c2ef24b04f59e Mon Sep 17 00:00:00 2001 From: Dan Elphick Date: Thu, 26 Jul 2018 09:57:26 +0000 Subject: Fix usage of deprecated V8 Value::ToString method Value::ToString is deprecated since the Isolate is inferred from the memory address of the object being converted to a string which will soon not be reliable. As such this method will be removed in the very near future. Change-Id: I1e5a1a0464f2052cc3aa5eeb1ddbdb7b0a9222d3 Reviewed-on: https://pdfium-review.googlesource.com/38914 Commit-Queue: Jochen Eisinger Reviewed-by: Jochen Eisinger --- fxjs/cjs_global.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/fxjs/cjs_global.cpp b/fxjs/cjs_global.cpp index efeef56b08..567d54853c 100644 --- a/fxjs/cjs_global.cpp +++ b/fxjs/cjs_global.cpp @@ -146,7 +146,8 @@ void CJS_Global::queryprop_static( ASSERT(property->IsString()); JSSpecialPropQuery( "global", - v8::Local::New(info.GetIsolate(), property->ToString()), + v8::Local::New(info.GetIsolate(), + property->ToString(info.GetIsolate())), info); } @@ -157,7 +158,8 @@ void CJS_Global::getprop_static( ASSERT(property->IsString()); JSSpecialPropGet( "global", - v8::Local::New(info.GetIsolate(), property->ToString()), + v8::Local::New(info.GetIsolate(), + property->ToString(info.GetIsolate())), info); } @@ -169,7 +171,8 @@ void CJS_Global::putprop_static( ASSERT(property->IsString()); JSSpecialPropPut( "global", - v8::Local::New(info.GetIsolate(), property->ToString()), + v8::Local::New(info.GetIsolate(), + property->ToString(info.GetIsolate())), value, info); } @@ -180,7 +183,8 @@ void CJS_Global::delprop_static( ASSERT(property->IsString()); JSSpecialPropDel( "global", - v8::Local::New(info.GetIsolate(), property->ToString()), + v8::Local::New(info.GetIsolate(), + property->ToString(info.GetIsolate())), info); } -- cgit v1.2.3