[Payments] Do not show error message in dialog view during close.
Attempting to show an error message in payment request dialog view after PaymentRequestDialogView::OnDialogClosed() call causes a crash. This is because PaymentRequestDialogView::ShowErrorMessage() creates an error view and adds it to the view stack[1] while the stack view gets destroyed upon PaymentRequestDialogView::OnDialogClosed() call. [1]https://source.chromium.org/chromium/chromium/src/+/master:chrome/browser/ui/views/payments/payment_request_dialog_view.cc;l=123 This cl fixes the crash by early-returning from PaymentRequestDialogView::ShowErrorMessage() when the dialog is getting closed (i.e after PaymentRequestDialogView::OnDialogClosed() has been called.) The screencast of the fix is already attached to the bug. Bug: 1114556 Change-Id: I10d9478a83913a167e52ed558a6a09cf18fcd6e4 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2359562Reviewed-by:Rouslan Solomakhin <rouslan@chromium.org> Commit-Queue: Sahel Sharify <sahel@chromium.org> Cr-Commit-Position: refs/heads/master@{#798860}
Showing
Please register or sign in to comment