| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/prerender/prerender_local_predictor.h" | 5 #include "chrome/browser/prerender/prerender_local_predictor.h" |
| 6 | 6 |
| 7 #include <ctype.h> | 7 #include <ctype.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 1315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1326 RecordEvent(EVENT_CONTINUE_PRERENDER_CHECK_LOGOUT_URL); | 1326 RecordEvent(EVENT_CONTINUE_PRERENDER_CHECK_LOGOUT_URL); |
| 1327 url_info.reset(NULL); | 1327 url_info.reset(NULL); |
| 1328 continue; | 1328 continue; |
| 1329 } | 1329 } |
| 1330 if (IsLogInURL(url_info->url)) { | 1330 if (IsLogInURL(url_info->url)) { |
| 1331 RecordEvent(EVENT_CONTINUE_PRERENDER_CHECK_LOGIN_URL); | 1331 RecordEvent(EVENT_CONTINUE_PRERENDER_CHECK_LOGIN_URL); |
| 1332 url_info.reset(NULL); | 1332 url_info.reset(NULL); |
| 1333 continue; | 1333 continue; |
| 1334 } | 1334 } |
| 1335 #if defined(FULL_SAFE_BROWSING) | 1335 #if defined(FULL_SAFE_BROWSING) |
| 1336 if (!SkipLocalPredictorWhitelist() && sb_db_manager && | 1336 if (!SkipLocalPredictorWhitelist() && sb_db_manager.get() && |
| 1337 sb_db_manager->CheckSideEffectFreeWhitelistUrl(url_info->url)) { | 1337 sb_db_manager->CheckSideEffectFreeWhitelistUrl(url_info->url)) { |
| 1338 // If a page is on the side-effect free whitelist, we will just prerender | 1338 // If a page is on the side-effect free whitelist, we will just prerender |
| 1339 // it without any additional checks. | 1339 // it without any additional checks. |
| 1340 RecordEvent(EVENT_CONTINUE_PRERENDER_CHECK_ON_SIDE_EFFECT_FREE_WHITELIST); | 1340 RecordEvent(EVENT_CONTINUE_PRERENDER_CHECK_ON_SIDE_EFFECT_FREE_WHITELIST); |
| 1341 IssuePrerender(info.get(), url_info.get()); | 1341 IssuePrerender(info.get(), url_info.get()); |
| 1342 num_issued++; | 1342 num_issued++; |
| 1343 continue; | 1343 continue; |
| 1344 } | 1344 } |
| 1345 #endif | 1345 #endif |
| 1346 if (!SkipLocalPredictorServiceWhitelist() && | 1346 if (!SkipLocalPredictorServiceWhitelist() && |
| (...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1562 break; | 1562 break; |
| 1563 case content::SessionStorageNamespace::MERGE_RESULT_MERGEABLE: | 1563 case content::SessionStorageNamespace::MERGE_RESULT_MERGEABLE: |
| 1564 RecordEvent(EVENT_NAMESPACE_MISMATCH_MERGE_RESULT_MERGEABLE); | 1564 RecordEvent(EVENT_NAMESPACE_MISMATCH_MERGE_RESULT_MERGEABLE); |
| 1565 break; | 1565 break; |
| 1566 default: | 1566 default: |
| 1567 NOTREACHED(); | 1567 NOTREACHED(); |
| 1568 } | 1568 } |
| 1569 } | 1569 } |
| 1570 | 1570 |
| 1571 } // namespace prerender | 1571 } // namespace prerender |
| OLD | NEW |