| Index: src/api.cc
|
| diff --git a/src/api.cc b/src/api.cc
|
| index 34a431d9b748846dc38768cb2298e1b75b45e30c..6808e418655edc5cd07abaafec744dbb1b7d4c1a 100644
|
| --- a/src/api.cc
|
| +++ b/src/api.cc
|
| @@ -5459,10 +5459,9 @@ Local<String> v8::String::Concat(Handle<String> left, Handle<String> right) {
|
| LOG_API(isolate, "String::New(char)");
|
| ENTER_V8(isolate);
|
| i::Handle<i::String> right_string = Utils::OpenHandle(*right);
|
| - i::Handle<i::String> result = isolate->factory()->NewConsString(left_string,
|
| - right_string);
|
| // We do not expect this to fail. Change this if it does.
|
| - CHECK(!result.is_null());
|
| + i::Handle<i::String> result = isolate->factory()->NewConsString(
|
| + left_string, right_string).ToHandleChecked();
|
| return Utils::ToLocal(result);
|
| }
|
|
|
| @@ -7019,15 +7018,15 @@ Handle<String> CpuProfileNode::GetFunctionName() const {
|
| i::Isolate* isolate = i::Isolate::Current();
|
| const i::ProfileNode* node = reinterpret_cast<const i::ProfileNode*>(this);
|
| const i::CodeEntry* entry = node->entry();
|
| + i::Handle<i::String> name =
|
| + isolate->factory()->InternalizeUtf8String(entry->name());
|
| if (!entry->has_name_prefix()) {
|
| - return ToApiHandle<String>(
|
| - isolate->factory()->InternalizeUtf8String(entry->name()));
|
| + return ToApiHandle<String>(name);
|
| } else {
|
| + // We do not expect this to fail. Change this if it does.
|
| i::Handle<i::String> cons = isolate->factory()->NewConsString(
|
| isolate->factory()->InternalizeUtf8String(entry->name_prefix()),
|
| - isolate->factory()->InternalizeUtf8String(entry->name()));
|
| - // We do not expect this to fail. Change this if it does.
|
| - CHECK(!cons.is_null());
|
| + name).ToHandleChecked();
|
| return ToApiHandle<String>(cons);
|
| }
|
| }
|
|
|