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

Side by Side Diff: content/browser/frame_host/navigation_handle_impl.h

Issue 2528813002: Fix Self-Referencing OOPIF Infinite Loop (Closed)
Patch Set: Add |state_| change in |WillStartRequest| and |WillRedirectRequest| Created 3 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_
6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_
7 7
8 #include "content/public/browser/navigation_handle.h" 8 #include "content/public/browser/navigation_handle.h"
9 9
10 #include <stddef.h> 10 #include <stddef.h>
(...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 // Helper function to run and reset the |complete_callback_|. This marks the 339 // Helper function to run and reset the |complete_callback_|. This marks the
340 // end of a round of NavigationThrottleChecks. 340 // end of a round of NavigationThrottleChecks.
341 void RunCompleteCallback(NavigationThrottle::ThrottleCheckResult result); 341 void RunCompleteCallback(NavigationThrottle::ThrottleCheckResult result);
342 342
343 // Used in tests. 343 // Used in tests.
344 State state() const { return state_; } 344 State state() const { return state_; }
345 345
346 // Populates |throttles_| with the throttles for this navigation. 346 // Populates |throttles_| with the throttles for this navigation.
347 void RegisterNavigationThrottles(); 347 void RegisterNavigationThrottles();
348 348
349 // Checks for attempts to navigate to a page that is already referenced more
350 // than once in its ancestors. This is a helper function used by
alexmos 2017/01/06 02:27:29 nit: s/its/the frame's/
davidsac (gone - try alexmos) 2017/01/19 18:26:23 Done.
351 // WillStartRequest and WillRedirectRequest to prevent the navigation.
352 bool IsSelfReferentialURL();
353
349 // See NavigationHandle for a description of those member variables. 354 // See NavigationHandle for a description of those member variables.
350 GURL url_; 355 GURL url_;
351 scoped_refptr<SiteInstance> starting_site_instance_; 356 scoped_refptr<SiteInstance> starting_site_instance_;
352 Referrer sanitized_referrer_; 357 Referrer sanitized_referrer_;
353 bool has_user_gesture_; 358 bool has_user_gesture_;
354 ui::PageTransition transition_; 359 ui::PageTransition transition_;
355 bool is_external_protocol_; 360 bool is_external_protocol_;
356 net::Error net_error_code_; 361 net::Error net_error_code_;
357 RenderFrameHostImpl* render_frame_host_; 362 RenderFrameHostImpl* render_frame_host_;
358 const bool is_renderer_initiated_; 363 const bool is_renderer_initiated_;
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 std::string searchable_form_encoding_; 449 std::string searchable_form_encoding_;
445 450
446 base::WeakPtrFactory<NavigationHandleImpl> weak_factory_; 451 base::WeakPtrFactory<NavigationHandleImpl> weak_factory_;
447 452
448 DISALLOW_COPY_AND_ASSIGN(NavigationHandleImpl); 453 DISALLOW_COPY_AND_ASSIGN(NavigationHandleImpl);
449 }; 454 };
450 455
451 } // namespace content 456 } // namespace content
452 457
453 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ 458 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698