Changeset 44420 in webkit


Ignore:
Timestamp:
Jun 4, 2009 11:34:23 AM (15 years ago)
Author:
bfulgham@webkit.org
Message:

2009-06-04 Jeremy Orlow <jorlow@chromium.org>

Reviewed by Darin Adler.

https://bugs.webkit.org/show_bug.cgi?id=26180
Add a fast path for SecurityOrigin::equal. If "other == this" (where
other is the other security origin), then we really don't need to do
all the other (expensive) comparisons. We know it's equal.

  • page/SecurityOrigin.cpp: (WebCore::SecurityOrigin::equal):
Location:
trunk/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r44416 r44420  
     12009-06-04  Jeremy Orlow  <jorlow@chromium.org>
     2
     3        Reviewed by Darin Adler.
     4
     5        https://bugs.webkit.org/show_bug.cgi?id=26180
     6        Add a fast path for SecurityOrigin::equal. If "other == this" (where
     7        other is the other security origin), then we really don't need to do
     8        all the other (expensive) comparisons. We know it's equal.
     9
     10        * page/SecurityOrigin.cpp:
     11        (WebCore::SecurityOrigin::equal):
     12
    1132009-06-03  David Hyatt  <hyatt@apple.com>
    214
  • trunk/WebCore/page/SecurityOrigin.cpp

    r41555 r44420  
    278278bool SecurityOrigin::equal(const SecurityOrigin* other) const
    279279{
     280    if (other == this)
     281        return true;
     282   
    280283    if (!isSameSchemeHostPort(other))
    281284        return false;
Note: See TracChangeset for help on using the changeset viewer.