Auto-rebaseline for r157319

http://src.chromium.org/viewvc/blink?view=revision&revision=157319

BUG=280709
TBR=ojan@chromium.org

Review URL: https://codereview.chromium.org/24013002

git-svn-id: svn://svn.chromium.org/blink/trunk@157327 bbb929c8-8fbe-4397-9dbb-9b2b20218538
WTF::OwnPtr should behave similarly with the rest of WTF smart pointers

Before the change OwnPtr could take either the pointer type or the pointed-to type, which was bad for the following reasons:
- It distinguished OwnPtr behaviour from other WTF smart pointer classes behaviour (so it was confusing for the Client).
- It was potential error-prone as it actually modified the type given by the Client in opaque way.

Review URL: https://chromiumcodereview.appspot.com/23960005

git-svn-id: svn://svn.chromium.org/blink/trunk@157328 bbb929c8-8fbe-4397-9dbb-9b2b20218538
The source of the problem are several assignments like this:

    static void subtractShapeIntervals(const ShapeIntervals& a, const ShapeIntervals& b, ShapeIntervals& result)
    {
        ... 

        const_iterator aNext = a.begin();
        const_iterator bNext = b.begin();
        ShapeInterval<T> aValue = *aNext;
        ShapeInterval<T> bValue = *bNext;

        while (aNext != a.end() && bNext != b.end()) {
            if (bValue.contains(aValue)) {
                aValue = *++aNext;   // BAD
            } 
        ....
    }

Although the LHS of the assignments aren't used when the corresponding iterator has reached its end, the expression still dereferences an invalid address (a.end() in this case).

The loop has been rewritten; we do not dereference the aNext or bNext iterators without checking the end condition.

BUG=285788

Review URL: https://chromiumcodereview.appspot.com/23454011

git-svn-id: svn://svn.chromium.org/blink/trunk@157329 bbb929c8-8fbe-4397-9dbb-9b2b20218538