Log Message
Unreviewed, rolling out r158299. http://trac.webkit.org/changeset/158299 https://bugs.webkit.org/show_bug.cgi?id=123558
caused assertion failures in fast/canvas/canvas-color- serialization.html and fast/forms/input-text-paste- maxlength.html (Requested by rniwa on #webkit). * wtf/text/StringStatics.cpp: (WTF::StringImpl::empty):
Modified Paths
Diff
Modified: trunk/Source/WTF/ChangeLog (158348 => 158349)
--- trunk/Source/WTF/ChangeLog 2013-10-31 06:27:02 UTC (rev 158348)
+++ trunk/Source/WTF/ChangeLog 2013-10-31 06:32:43 UTC (rev 158349)
@@ -1,3 +1,16 @@
+2013-10-30 Commit Queue <commit-qu...@webkit.org>
+
+ Unreviewed, rolling out r158299.
+ http://trac.webkit.org/changeset/158299
+ https://bugs.webkit.org/show_bug.cgi?id=123558
+
+ caused assertion failures in fast/canvas/canvas-color-
+ serialization.html and fast/forms/input-text-paste-
+ maxlength.html (Requested by rniwa on #webkit).
+
+ * wtf/text/StringStatics.cpp:
+ (WTF::StringImpl::empty):
+
2013-10-30 Ryosuke Niwa <rn...@webkit.org>
Remove code for Mac Lion
Modified: trunk/Source/WTF/wtf/text/StringStatics.cpp (158348 => 158349)
--- trunk/Source/WTF/wtf/text/StringStatics.cpp 2013-10-31 06:27:02 UTC (rev 158348)
+++ trunk/Source/WTF/wtf/text/StringStatics.cpp 2013-10-31 06:32:43 UTC (rev 158349)
@@ -43,7 +43,15 @@
StringImpl* StringImpl::empty()
{
- DEFINE_STATIC_LOCAL(StringImpl, emptyString, (reinterpret_cast<UChar*>(static_cast<intptr_t>(8)), 0, ConstructStaticString));
+ // FIXME: This works around a bug in our port of PCRE, that a regular _expression_
+ // run on the empty string may still perform a read from the first element, and
+ // as such we need this to be a valid pointer. No code should ever be reading
+ // from a zero length string, so this should be able to be a non-null pointer
+ // into the zero-page.
+ // Replace this with 'reinterpret_cast<UChar*>(static_cast<intptr_t>(1))' once
+ // PCRE goes away.
+ static LChar emptyLCharData = 0;
+ DEFINE_STATIC_LOCAL(StringImpl, emptyString, (&emptyLCharData, 0, ConstructStaticString));
WTF_ANNOTATE_BENIGN_RACE(&emptyString, "Benign race on StringImpl::emptyString reference counter");
return &emptyString;
}
_______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes