[EFL] Unskipping some Accessibility Layout Tests for WK2.
https://bugs.webkit.org/show_bug.cgi?id=107555

Unreviewed EFL gardening.

Patch by Krzysztof Czech <k.czech@samsung.com> on 2013-01-22

* platform/efl-wk2/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140424 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r140420.
http://trac.webkit.org/changeset/140420
https://bugs.webkit.org/show_bug.cgi?id=107557

Still causes crashes (EFL this time) (Requested by kov on
#webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-01-22

* platform/graphics/gstreamer/GStreamerVersioning.cpp:
* platform/graphics/gstreamer/GStreamerVersioning.h:
* platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
(StreamingClient):
(_WebKitWebSrcPrivate):
(webKitWebSrcFinalize):
(webKitWebSrcStop):
(StreamingClient::didReceiveData):
* platform/network/ResourceHandleClient.h:
(ResourceHandleClient):
* platform/network/ResourceHandleInternal.h:
(WebCore::ResourceHandleInternal::ResourceHandleInternal):
(ResourceHandleInternal):
* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::cleanupSoupRequestOperation):
(WebCore::nextMultipartResponsePartCallback):
(WebCore::sendRequestCallback):
(WebCore::readCallback):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140425 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: [Network] "Secure" cookies can not be deleted.
https://bugs.webkit.org/show_bug.cgi?id=107543

Patch by Eugene Klyuchnikov <eustas@chromium.org> on 2013-01-22
Reviewed by Pavel Feldman.

To delete secure cookie URL schema need to be "https" instead of "http".

* inspector/front-end/CookieItemsView.js:
(WebInspector.CookieItemsView.prototype._deleteCookie):
Take care of secure cookies.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140426 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: remove asynchronous behavior from DTE paintLines method
https://bugs.webkit.org/show_bug.cgi?id=107550

Patch by Andrey Lushnikov <lushnikov@chromium.org> on 2013-01-22
Reviewed by Pavel Feldman.

Remove paintLinesOperationCredit and all asynchronous behaviour from paintLines method;
also, remove paintLineChunks method.

* inspector/front-end/DefaultTextEditor.js:
(WebInspector.TextEditorMainPanel.prototype.expandChunks):
(WebInspector.TextEditorMainPanel.prototype._highlightDataReady):
(WebInspector.TextEditorMainPanel.prototype._paintLines):
(WebInspector.TextEditorMainPanel.prototype._renderRanges):
(WebInspector.TextEditorMainPanel.prototype._paintLine):
(WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140427 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: [Canvas] jump to prev/next drawing call in the replay
https://bugs.webkit.org/show_bug.cgi?id=107551

Reviewed by Pavel Feldman.

Implement jumping to the next(previous) drawing call in the WebGL and canvas 2D replay.

* English.lproj/localizedStrings.js:
* inspector/InjectedScriptCanvasModuleSource.js:
(.):
* inspector/Inspector.json:
* inspector/front-end/CanvasProfileView.js:
(WebInspector.CanvasProfileView):
(WebInspector.CanvasProfileView.prototype.dispose):
(WebInspector.CanvasProfileView.prototype._onReplayDrawingCallClick):
* inspector/front-end/canvasProfiler.css:
(.canvas-replay-prev-draw img):
(.canvas-replay-next-draw img):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140428 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Asserts when textPath is used with no path
https://bugs.webkit.org/show_bug.cgi?id=107324

Reviewed by Eric Seidel.

Source/WebCore: 

We assert when there is no path associated with an SVG text path
element. Instead, this patch detects the condition and stops trying to
layout text for that textPath  element.

Test: svg/text/tpath-without-path.svg

* rendering/svg/SVGTextLayoutEngine.cpp:
(WebCore::SVGTextLayoutEngine::beginTextPathLayout):
(WebCore::SVGTextLayoutEngine::layoutTextOnLineOrPath):

LayoutTests: 

Test will assert in debug without this patch.

* svg/text/tpath-without-path-expected.txt: Added.
* svg/text/tpath-without-path.svg: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140429 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Autotools] Place a warning in configure.ac about adding new configuration options
https://bugs.webkit.org/show_bug.cgi?id=107559

Reviewed by Martin Robinson.

* configure.ac: Add an eye-catching section explaining that changes in this file might
not be necessary at all and a link pointing to the guidelines on the Trac wiki.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140430 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Autotools] Remove the Canvas Path configuration option
https://bugs.webkit.org/show_bug.cgi?id=107537

Reviewed by Martin Robinson.

.: 

* configure.ac: Remove the configuration option for the Canvas Path
feature as this is not in line with the new guidelines about feature
enablement in the autotools build system.

Source/WebCore: 

No new tests - no new testable functionality.

* GNUmakefile.am: Remove the Automake conditional analysis, the related
configuration option is being removed as well.
* GNUmakefile.features.am.in: Add the ENABLE_CANVAS_PATH feature define,
defaulting to 0 in release builds (but is disabled in development builds
of the GTK port as well at the moment).


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140431 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Silence MSVC 64-bit build warning c4309 for FrameTree::invalidCount
https://bugs.webkit.org/show_bug.cgi?id=107439

Reviewed by Dimitri Glazkov.

MSVC detects that the constant notFound is truncated on assignment to
invalidCount. Since we never compare them (as it would always fail on
64-bit anyway), just initialize invalidCount directly to -1.

No new tests. No behavior changed.

* page/FrameTree.h:
(FrameTree):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140433 268f45cc-cd09-0410-ab3c-d52691b4dbfc
        One is not allowed to use commit-queue to make oneself a committer.

        * Scripts/webkitpy/common/config/committers.py: Removing eustas@chromium.org.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140434 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Heap-use-after-free in WebCore::RenderObject::isDescendantOf
https://bugs.webkit.org/show_bug.cgi?id=107226

Reviewed by Emil A Eklund.

Source/WebCore:

Test: fast/block/float/overhanging-float-not-removed-crash.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::removeFloatingOrPositionedChildFromBlockLists):
Skip anonymous blocks in the chain to get the enclosing block and
be able to correctly mark the overhanging floats in the next siblings.

LayoutTests:

* fast/block/float/overhanging-float-not-removed-crash-expected.txt: Added.
* fast/block/float/overhanging-float-not-removed-crash.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140435 268f45cc-cd09-0410-ab3c-d52691b4dbfc
When we do setAttribute("border", null) on a table we should create a border like every other browser
https://bugs.webkit.org/show_bug.cgi?id=102112

Reviewed by Ryosuke Niwa.

Source/WebCore:

http://www.whatwg.org/specs/web-apps/current-work/multipage/rendering.html#tables says:
"If the [table's border] attribute is present but parsing the attribute's value using the rules for parsing
non-negative integers generates an error, a default value of 1px is expected to be used for that property instead."

Match the spec and bring us into line with other browsers by observing the 'parsing non-negative integers' algorithm.

Tests: fast/dom/HTMLTableElement/table-with-invalid-border.html
       fast/table/table-with-borderattr-null.html
       fast/table/table-with-borderattr-set-to-null.html

* html/HTMLElement.cpp:
(WebCore::HTMLElement::parseBorderWidthAttribute):
(WebCore::HTMLElement::applyBorderAttributeToStyle):
* html/HTMLElement.h:
(HTMLElement):
* html/HTMLTableElement.cpp:
(WebCore::HTMLTableElement::collectStyleForPresentationAttribute):
(WebCore::HTMLTableElement::parseAttribute):

LayoutTests:

* fast/dom/HTMLTableElement/table-with-invalid-border-expected.txt: Added.
* fast/dom/HTMLTableElement/table-with-invalid-border.html: Added.
* fast/table/table-with-borderattr-null-expected.txt: Added.
* fast/table/table-with-borderattr-null.html: Added.
* fast/table/table-with-borderattr-set-to-null-expected.txt: Added.
* fast/table/table-with-borderattr-set-to-null.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140436 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix DateMath.cpp to compile with -Wshorten-64-to-32
<http://webkit.org/b/107503>

Reviewed by Darin Adler.

Source/JavaScriptCore:

* runtime/JSDateMath.cpp:
(JSC::parseDateFromNullTerminatedCharacters): Remove unneeded
static_cast<int>().

Source/WTF:

Fixes the following build errors with -Wshorten-64-to-32:

    DateMath.cpp:742:47: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        if (month == 2 && day > 28 && !isLeapYear(year))
                                       ~~~~~~~~~~ ^~~~
    DateMath.cpp:757:48: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        double dateSeconds = ymdhmsToSeconds(year, month, day, hours, minutes, seconds) - timeZoneSeconds;
                             ~~~~~~~~~~~~~~~       ^~~~~
    DateMath.cpp:757:55: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        double dateSeconds = ymdhmsToSeconds(year, month, day, hours, minutes, seconds) - timeZoneSeconds;
                             ~~~~~~~~~~~~~~~              ^~~
    DateMath.cpp:757:60: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        double dateSeconds = ymdhmsToSeconds(year, month, day, hours, minutes, seconds) - timeZoneSeconds;
                             ~~~~~~~~~~~~~~~                   ^~~~~
    DateMath.cpp:757:67: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        double dateSeconds = ymdhmsToSeconds(year, month, day, hours, minutes, seconds) - timeZoneSeconds;
                             ~~~~~~~~~~~~~~~                          ^~~~~~~
    DateMath.cpp:996:59: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
                        offset = ((o / 100) * 60 + (o % 100)) * sgn;
                               ~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
    DateMath.cpp:998:37: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
                        offset = o * 60 * sgn;
                               ~ ~~~~~~~^~~~~
    DateMath.cpp:1005:40: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
                    offset = (o * 60 + o2) * sgn;
                           ~ ~~~~~~~~~~~~~~^~~~~
    DateMath.cpp:1041:40: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        return ymdhmsToSeconds(year, month + 1, day, hour, minute, second) * msPerSecond;
               ~~~~~~~~~~~~~~~       ~~~~~~^~~
    DateMath.cpp:1041:45: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        return ymdhmsToSeconds(year, month + 1, day, hour, minute, second) * msPerSecond;
               ~~~~~~~~~~~~~~~                  ^~~
    DateMath.cpp:1041:50: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        return ymdhmsToSeconds(year, month + 1, day, hour, minute, second) * msPerSecond;
               ~~~~~~~~~~~~~~~                       ^~~~
    DateMath.cpp:1041:56: error: implicit conversion loses integer precision: 'long' to 'int' [-Werror,-Wshorten-64-to-32]
        return ymdhmsToSeconds(year, month + 1, day, hour, minute, second) * msPerSecond;
               ~~~~~~~~~~~~~~~                             ^~~~~~
    12 errors generated.

* wtf/DateMath.cpp:
(WTF::ymdhmsToSeconds): Change year argument from long to int.
Change mon, day, hour, minute arguments from int to long.
(WTF::parseInt): Add.  Identical to parseLong but bounds checks
for type int.
(WTF::parseLong): Switch to std::numeric_limits<long> instead of
macros.
(WTF::parseES5DatePortion): Change year argument from long to
int.
(WTF::parseES5DateFromNullTerminatedCharacters): Change year
local variable from long to int.
(WTF::parseDateFromNullTerminatedCharacters): Change year and
offset local variables from long to int.  Switch from using
parseLong() to parseInt() as needed.  Ditto for labs() to abs().
Add overflow check when switching from "MM/DD/YYYY" to
"YYYY/MM/DD" parsing.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140437 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Yarr JIT isn't big endian compatible
https://bugs.webkit.org/show_bug.cgi?id=102897

Patch by Tobias Netzel <tobias.netzel@googlemail.com> on 2013-01-22
Reviewed by Oliver Hunt.

This patch was tested in the current mozilla codebase only and has passed the regexp tests there.

* yarr/YarrJIT.cpp:
(JSC::Yarr::YarrGenerator::generatePatternCharacterOnce):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140438 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r140435.
http://trac.webkit.org/changeset/140435
https://bugs.webkit.org/show_bug.cgi?id=107565

Crashes on ClusterFuzz due to float not removed (Requested by
inferno-sec on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-01-22

Source/WebCore:

* rendering/RenderBox.cpp:
(WebCore::RenderBox::removeFloatingOrPositionedChildFromBlockLists):

LayoutTests:

* fast/block/float/overhanging-float-not-removed-crash-expected.txt: Removed.
* fast/block/float/overhanging-float-not-removed-crash.html: Removed.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140439 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Debug build failure on x86-64
https://bugs.webkit.org/show_bug.cgi?id=107400

Reviewed by Xan Lopez.

* configure.ac: use thin archives for convenience libraries, if AR_FLAGS was not
overriden through the environment variable.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140440 268f45cc-cd09-0410-ab3c-d52691b4dbfc
BackgroundHTMLParser should simulate tree building in a separate function
https://bugs.webkit.org/show_bug.cgi?id=107569

Reviewed by Eric Seidel.

This patch cleans up BackgroundHTMLParser::pumpTokenizer to prepare for
implementing speculative parsing.

* html/parser/BackgroundHTMLParser.cpp:
(WebCore::BackgroundHTMLParser::simulateTreeBuilder):
(WebCore):
(WebCore::BackgroundHTMLParser::pumpTokenizer):
* html/parser/BackgroundHTMLParser.h:
(BackgroundHTMLParser):
* page/Settings.in:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140441 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION(r140344): Repeated crashes in WKTR PlatformWebView::viewSupportsOptions().
https://bugs.webkit.org/show_bug.cgi?id=107562

Rubber-stamped by Alexy Proskuryakov.

The input to WKBooleanGetValue() is not NULL-safe, so NULL check its inputs before calling.

* WebKitTestRunner/mac/PlatformWebViewMac.mm:
(WTR::PlatformWebView::PlatformWebView):
(WTR::PlatformWebView::viewSupportsOptions):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140442 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[gstreamer] GstBus signal watch should be removed on clean up
https://bugs.webkit.org/show_bug.cgi?id=107544

Reviewed by Philippe Normand.

Our gstreamer backend code currently calls gst_bus_add_signal_watch()
on GstBus to add a signal watch. As per the gstreamer  documentation,
"To clean up, the caller is responsible for calling
gst_bus_remove_signal_watch() as many times as this function is
called". This is because gst_bus_add_signal_watch() causes the GstBus
object to be ref'd and gst_bus_remove_signal_watch() needs to be
called to properly unref it.

This patch makes sure that gst_bus_remove_signal_watch() is called
on the GstBus object when cleaning up. This patch also uses smart
pointers for GstBus objects for consistency.

No new tests, no behavior change for layout tests.

* platform/audio/gstreamer/AudioDestinationGStreamer.cpp:
(WebCore::AudioDestinationGStreamer::AudioDestinationGStreamer):
(WebCore::AudioDestinationGStreamer::~AudioDestinationGStreamer):
* platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
(WebCore::AudioFileReader::~AudioFileReader):
(WebCore::AudioFileReader::decodeAudioForBusCreation):
* platform/graphics/gstreamer/GStreamerGWorld.cpp:
(WebCore::GStreamerGWorld::GStreamerGWorld):
* platform/graphics/gstreamer/GStreamerVersioning.cpp:
(webkitGstPipelineGetBus):
* platform/graphics/gstreamer/GStreamerVersioning.h:
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140443 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Soup] Random thread crashes
https://bugs.webkit.org/show_bug.cgi?id=107439

Reviewed by Martin Robinson.

Process all pending requests in the inner GMainContext created to
perform synchronous requests before restoring the thread default. No
new tests required, already covered by network tests.

* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::WebCoreSynchronousLoader::~WebCoreSynchronousLoader):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140445 268f45cc-cd09-0410-ab3c-d52691b4dbfc