Commit 054e1779 authored by jbroman's avatar jbroman Committed by Commit bot

ValueSerializer: Don't throw an exception after SetPropertiesFromKeyValuePairs fails.

It always throws an exception in the cases that it fails, so throwing another
doesn't help things.

BUG=chromium:664416

Review-Url: https://codereview.chromium.org/2495393002
Cr-Commit-Position: refs/heads/master@{#40999}
parent a63eeb48
......@@ -1797,8 +1797,7 @@ ValueDeserializer::ReadObjectUsingEntireBufferForLegacyFormat() {
!SetPropertiesFromKeyValuePairs(
isolate_, js_object, &stack[begin_properties], num_properties)
.FromMaybe(false)) {
isolate_->Throw(*isolate_->factory()->NewError(
MessageTemplate::kDataCloneDeserializationError));
DCHECK(isolate_->has_pending_exception());
return MaybeHandle<Object>();
}
......@@ -1829,8 +1828,7 @@ ValueDeserializer::ReadObjectUsingEntireBufferForLegacyFormat() {
!SetPropertiesFromKeyValuePairs(
isolate_, js_array, &stack[begin_properties], num_properties)
.FromMaybe(false)) {
isolate_->Throw(*isolate_->factory()->NewError(
MessageTemplate::kDataCloneDeserializationError));
DCHECK(isolate_->has_pending_exception());
return MaybeHandle<Object>();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment