2008-08-06 Marco Barisione <marco.barisione@collabora.co.uk>
authorjmalonzo@webkit.org <jmalonzo@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 6 Aug 2008 12:46:40 +0000 (12:46 +0000)
committerjmalonzo@webkit.org <jmalonzo@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 6 Aug 2008 12:46:40 +0000 (12:46 +0000)
commitafb945932fcae04a9c757cb70b69d5def9f49ee7
treea9ade2bfba80620a1a95b330556c76a65e1635eb
parent7d79005daf4a75ba269e9e9a57913237cda2d0f0
2008-08-06  Marco Barisione  <marco.barisione@collabora.co.uk>

        Reviewed by Eric Seidel.

        http://bugs.webkit.org/show_bug.cgi?id=20295
        RegularExpression::match should not crash when a null string is passed

        RegularExpression::match used to pass null subject strings to
        jsRegExpExecute causing an ASSERT failure and then a crash.
        There is no need to fix also RegularExpression:search and
        RegularExpression::searchRev as they just call
        RegularExpression::match.

        * platform/text/RegularExpression.cpp:
        (WebCore::RegularExpression::match): Return -1 if the string is null.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@35601 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebCore/ChangeLog
WebCore/platform/text/RegularExpression.cpp