Changeset 131663 in webkit


Ignore:
Timestamp:
Oct 17, 2012 4:12:15 PM (11 years ago)
Author:
allan.jensen@digia.com
Message:

[Qt] Certain SVG content freezes QtWebKit
https://bugs.webkit.org/show_bug.cgi?id=97258

Reviewed by Simon Hausmann.

Source/WebCore:

Ensure dashpattern is well-formed by avoiding divisions by zero.

Test: svg/stroke/zero-width-hang.html

  • platform/graphics/qt/GraphicsContextQt.cpp:

(WebCore::GraphicsContext::setLineDash):

LayoutTests:

  • svg/stroke/zero-width-hang-expected.txt: Added.
  • svg/stroke/zero-width-hang.html: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r131662 r131663  
     12012-10-17  Allan Sandfeld Jensen  <allan.jensen@digia.com>
     2
     3        [Qt] Certain SVG content freezes QtWebKit
     4        https://bugs.webkit.org/show_bug.cgi?id=97258
     5
     6        Reviewed by Simon Hausmann.
     7
     8        * svg/stroke/zero-width-hang-expected.txt: Added.
     9        * svg/stroke/zero-width-hang.html: Added.
     10
    1112012-10-17  Filip Pizlo  <fpizlo@apple.com>
    212
  • trunk/Source/WebCore/ChangeLog

    r131661 r131663  
     12012-10-17  Allan Sandfeld Jensen  <allan.jensen@digia.com>
     2
     3        [Qt] Certain SVG content freezes QtWebKit
     4        https://bugs.webkit.org/show_bug.cgi?id=97258
     5
     6        Reviewed by Simon Hausmann.
     7
     8        Ensure dashpattern is well-formed by avoiding divisions by zero.
     9
     10        Test: svg/stroke/zero-width-hang.html
     11
     12        * platform/graphics/qt/GraphicsContextQt.cpp:
     13        (WebCore::GraphicsContext::setLineDash):
     14
    1152012-10-17  Alec Flett  <alecflett@chromium.org>
    216
  • trunk/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp

    r131065 r131663  
    11911191
    11921192        float penWidth = narrowPrecisionToFloat(double(pen.widthF()));
     1193        if (penWidth <= 0.f)
     1194            penWidth = 1.f;
     1195
    11931196        for (unsigned i = 0; i < count; i++)
    11941197            pattern.append(dashes[i % dashLength] / penWidth);
Note: See TracChangeset for help on using the changeset viewer.