Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Unified Diff: src/value-serializer.cc

Issue 2495393002: ValueSerializer: Don't throw an exception after SetPropertiesFromKeyValuePairs fails. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/value-serializer.cc
diff --git a/src/value-serializer.cc b/src/value-serializer.cc
index 0346b02d58bcf4a0398722073301464ea88793b8..c6abb8a85cda9166e29a2ce890e2742f56290f1b 100644
--- a/src/value-serializer.cc
+++ b/src/value-serializer.cc
@@ -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>();
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698