summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/runtime/StringRecursionChecker.cpp
diff options
context:
space:
mode:
authoralexis <alexis@webkit.org>2013-01-10 13:46:39 +0000
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-01-10 17:00:10 +0100
commit1ced62033ffe82134c2f5707b6ef197fa3e85375 (patch)
treece7d277290288dfbdd61413e86142b5e19576475 /Source/JavaScriptCore/runtime/StringRecursionChecker.cpp
parentf8fc2a310cd32d4c577675c3b943345df033b84c (diff)
downloadqtwebkit-1ced62033ffe82134c2f5707b6ef197fa3e85375.tar.gz
ASSERT_NOT_REACHED in StylePropertySet::fontValue when accessing font style property through JS after setting style font size.
https://bugs.webkit.org/show_bug.cgi?id=88866 Reviewed by Alexander Pavlov. Source/WebCore: StylePropertySet::fontValue always assumed that it was called using style.font after a subsequent call which set the shorthand font. The ASSERT_NOT_REACHED assumed that all longhands of the font shorthand not set by the shorthand itself were set to initial. While it's true when we set the font shorthand (i.e all longhands are set to implicit initial) it is not true when you set the longhands individually. For example setting font-size will not set other font properties to initial. It is the behavior of all other shorthands in WebKit. When reconstructing the shorthand other properties tests whether the value of each longhands is initial or not (if not then we omit the value, as we should always construct the shortest shorthand possible) or if the value is set or not (if set then we include it in the shorthand if not then we omit it). The comment removed was also talking about invalid font property potentially built by fontValue(). So far appendFontLonghandValueIfExplicit will always construct a valid value as it takes care of adding ' ' or '/' when needed, so the return value is parsable and correct. Test: fast/css/font-shorthand-from-longhands.html * css/StylePropertySet.cpp: (WebCore::StylePropertySet::appendFontLonghandValueIfExplicit): (WebCore::StylePropertySet::fontValue): * css/StylePropertySet.h: git-svn-id: http://svn.webkit.org/repository/webkit/trunk@139313 268f45cc-cd09-0410-ab3c-d52691b4dbfc Change-Id: I46a4b1d023f3cb8f4e7b4c0b7f176b5b9f850870 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'Source/JavaScriptCore/runtime/StringRecursionChecker.cpp')
0 files changed, 0 insertions, 0 deletions