OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/net/connection_tester.h" | 5 #include "chrome/browser/net/connection_tester.h" |
6 | 6 |
7 #include "chrome/test/base/testing_pref_service.h" | 7 #include "chrome/test/base/testing_pref_service.h" |
8 #include "content/test/test_browser_thread.h" | 8 #include "content/test/test_browser_thread.h" |
9 #include "net/base/cert_verifier.h" | 9 #include "net/base/cert_verifier.h" |
10 #include "net/base/cookie_monster.h" | 10 #include "net/base/cookie_monster.h" |
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 tester.reset(); | 187 tester.reset(); |
188 | 188 |
189 // Drain the tasks on the message loop. | 189 // Drain the tasks on the message loop. |
190 // | 190 // |
191 // Note that we cannot simply stop the message loop, since that will delete | 191 // Note that we cannot simply stop the message loop, since that will delete |
192 // any pending tasks instead of running them. This causes a problem with | 192 // any pending tasks instead of running them. This causes a problem with |
193 // net::ClientSocketPoolBaseHelper, since the "Group" holds a pointer | 193 // net::ClientSocketPoolBaseHelper, since the "Group" holds a pointer |
194 // |backup_task| that it will try to deref during the destructor, but | 194 // |backup_task| that it will try to deref during the destructor, but |
195 // depending on the order that pending tasks were deleted in, it might | 195 // depending on the order that pending tasks were deleted in, it might |
196 // already be invalid! See http://crbug.com/43291. | 196 // already be invalid! See http://crbug.com/43291. |
197 MessageLoop::current()->PostTask(FROM_HERE, new MessageLoop::QuitTask()); | 197 MessageLoop::current()->PostTask(FROM_HERE, MessageLoop::QuitClosure()); |
198 MessageLoop::current()->Run(); | 198 MessageLoop::current()->Run(); |
199 } | 199 } |
200 | 200 |
201 } // namespace | 201 } // namespace |
OLD | NEW |