Index: third_party/WebKit/Source/modules/payments/PaymentRequest.cpp |
diff --git a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp |
index 495f73e805dc13310cd77b78dbb345844168c341..7c6eb2818dd0c12214a86b9fadcada0c95b52645 100644 |
--- a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp |
+++ b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp |
@@ -28,6 +28,7 @@ |
#include "mojo/public/cpp/bindings/wtf_array.h" |
#include "platform/mojo/MojoHelper.h" |
#include "public/platform/InterfaceProvider.h" |
+#include "public/platform/Platform.h" |
#include "public/platform/WebTraceLocation.h" |
#include "wtf/HashSet.h" |
#include <utility> |
@@ -792,6 +793,11 @@ void PaymentRequest::OnPaymentResponse( |
} |
void PaymentRequest::OnError(mojo::PaymentErrorReason error) { |
+ if (!Platform::current()) { |
+ // TODO(rockot): Clean this up once renderer shutdown sequence is fixed. |
+ return; |
+ } |
+ |
bool isError = false; |
ExceptionCode ec = UnknownError; |
String message; |