OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> | 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> |
3 * 1999 Lars Knoll <knoll@kde.org> | 3 * 1999 Lars Knoll <knoll@kde.org> |
4 * 1999 Antti Koivisto <koivisto@kde.org> | 4 * 1999 Antti Koivisto <koivisto@kde.org> |
5 * 2000 Simon Hausmann <hausmann@kde.org> | 5 * 2000 Simon Hausmann <hausmann@kde.org> |
6 * 2000 Stefan Schimanski <1Stein@gmx.de> | 6 * 2000 Stefan Schimanski <1Stein@gmx.de> |
7 * 2001 George Staikos <staikos@kde.org> | 7 * 2001 George Staikos <staikos@kde.org> |
8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> | 9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> |
10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
(...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
693 return nextCharacterRange.release(); | 693 return nextCharacterRange.release(); |
694 } | 694 } |
695 | 695 |
696 return nullptr; | 696 return nullptr; |
697 } | 697 } |
698 | 698 |
699 bool LocalFrame::isURLAllowed(const KURL& url) const | 699 bool LocalFrame::isURLAllowed(const KURL& url) const |
700 { | 700 { |
701 // We allow one level of self-reference because some sites depend on that, | 701 // We allow one level of self-reference because some sites depend on that, |
702 // but we don't allow more than one. | 702 // but we don't allow more than one. |
703 if (host()->subframeCount() >= FrameHost::maxNumberOfFrames) | |
704 return false; | |
705 bool foundSelfReference = false; | 703 bool foundSelfReference = false; |
706 for (const Frame* frame = this; frame; frame = frame->tree().parent()) { | 704 for (const Frame* frame = this; frame; frame = frame->tree().parent()) { |
707 if (!frame->isLocalFrame()) | 705 if (!frame->isLocalFrame()) |
708 continue; | 706 continue; |
709 if (equalIgnoringFragmentIdentifier(toLocalFrame(frame)->document()->url
(), url)) { | 707 if (equalIgnoringFragmentIdentifier(toLocalFrame(frame)->document()->url
(), url)) { |
710 if (foundSelfReference) | 708 if (foundSelfReference) |
711 return false; | 709 return false; |
712 foundSelfReference = true; | 710 foundSelfReference = true; |
713 } | 711 } |
714 } | 712 } |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
823 , m_textZoomFactor(parentTextZoomFactor(this)) | 821 , m_textZoomFactor(parentTextZoomFactor(this)) |
824 , m_inViewSourceMode(false) | 822 , m_inViewSourceMode(false) |
825 { | 823 { |
826 if (isLocalRoot()) | 824 if (isLocalRoot()) |
827 m_instrumentingAgents = InstrumentingAgents::create(); | 825 m_instrumentingAgents = InstrumentingAgents::create(); |
828 else | 826 else |
829 m_instrumentingAgents = localFrameRoot()->m_instrumentingAgents; | 827 m_instrumentingAgents = localFrameRoot()->m_instrumentingAgents; |
830 } | 828 } |
831 | 829 |
832 } // namespace blink | 830 } // namespace blink |
OLD | NEW |