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

Unified Diff: chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa_browsertest.mm

Issue 16054005: [ASAN] Fix use-after-free. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Enable test. Created 7 years, 7 months 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: chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa_browsertest.mm
diff --git a/chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa_browsertest.mm b/chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa_browsertest.mm
index 888087f64754e25329083c26a7d172cefc87a2dc..7e768486ad9260b05dbffd13087055c00896c051 100644
--- a/chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa_browsertest.mm
+++ b/chrome/browser/ui/cocoa/autofill/autofill_dialog_cocoa_browsertest.mm
@@ -45,13 +45,8 @@ class TestAutofillDialogController : public AutofillDialogControllerImpl {
virtual void ViewClosed() OVERRIDE {
DCHECK(runner_);
- AutofillDialogControllerImpl::ViewClosed();
runner_->Quit();
- }
-
- void RunMessageLoop() {
- DCHECK(runner_);
- runner_->Run();
+ AutofillDialogControllerImpl::ViewClosed();
}
AutofillDialogCocoa* GetView() {
@@ -96,6 +91,11 @@ class AutofillDialogCocoaBrowserTest : public InProcessBrowserTest {
TestAutofillDialogController* controller() { return controller_; }
+ void RunMessageLoop() {
+ DCHECK(runner_);
+ runner_->Run();
+ }
+
private:
// The controller owns itself.
TestAutofillDialogController* controller_;
@@ -107,19 +107,12 @@ class AutofillDialogCocoaBrowserTest : public InProcessBrowserTest {
DISALLOW_COPY_AND_ASSIGN(AutofillDialogCocoaBrowserTest);
};
-// The following test fails under ASAN due to a read-after-free.
-// http://crbug.com/234008
-#if defined(ADDRESS_SANITIZER)
-#define MAYBE_DisplayUI DISABLED_DisplayUI
-#else
-#define MAYBE_DisplayUI DisplayUI
-#endif
-IN_PROC_BROWSER_TEST_F(AutofillDialogCocoaBrowserTest, MAYBE_DisplayUI) {
+IN_PROC_BROWSER_TEST_F(AutofillDialogCocoaBrowserTest, DisplayUI) {
controller()->Show();
controller()->OnCancel();
controller()->Hide();
- controller()->RunMessageLoop();
+ RunMessageLoop();
}
} // namespace
« 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