Title: [88610] trunk/Source/WebCore
- Revision
- 88610
- Author
- [email protected]
- Date
- 2011-06-11 21:19:39 -0700 (Sat, 11 Jun 2011)
Log Message
2011-06-11 Adam Barth <[email protected]>
Reviewed by Darin Adler.
Remove unnecessary strlen from DocumentWriter
https://bugs.webkit.org/show_bug.cgi?id=62505
This ugly piece of code appears not to be needed. Rejoice.
* WebCore.exp.in:
* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::commitData):
* loader/DocumentLoader.h:
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::addData):
* loader/DocumentWriter.h:
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (88609 => 88610)
--- trunk/Source/WebCore/ChangeLog 2011-06-12 00:51:11 UTC (rev 88609)
+++ trunk/Source/WebCore/ChangeLog 2011-06-12 04:19:39 UTC (rev 88610)
@@ -2,6 +2,23 @@
Reviewed by Darin Adler.
+ Remove unnecessary strlen from DocumentWriter
+ https://bugs.webkit.org/show_bug.cgi?id=62505
+
+ This ugly piece of code appears not to be needed. Rejoice.
+
+ * WebCore.exp.in:
+ * loader/DocumentLoader.cpp:
+ (WebCore::DocumentLoader::commitData):
+ * loader/DocumentLoader.h:
+ * loader/DocumentWriter.cpp:
+ (WebCore::DocumentWriter::addData):
+ * loader/DocumentWriter.h:
+
+2011-06-11 Adam Barth <[email protected]>
+
+ Reviewed by Darin Adler.
+
DocumentParser::appendBytes shouldn't have a "flush" boolean parameter
https://bugs.webkit.org/show_bug.cgi?id=62499
Modified: trunk/Source/WebCore/WebCore.exp.in (88609 => 88610)
--- trunk/Source/WebCore/WebCore.exp.in 2011-06-12 00:51:11 UTC (rev 88609)
+++ trunk/Source/WebCore/WebCore.exp.in 2011-06-12 04:19:39 UTC (rev 88610)
@@ -332,7 +332,7 @@
__ZN7WebCore14CachedResource12removeClientEPNS_20CachedResourceClientE
__ZN7WebCore14CachedResource16unregisterHandleEPNS_24CachedResourceHandleBaseE
__ZN7WebCore14CachedResource9addClientEPNS_20CachedResourceClientE
-__ZN7WebCore14DocumentLoader10commitDataEPKci
+__ZN7WebCore14DocumentLoader10commitDataEPKcm
__ZN7WebCore14DocumentLoader13attachToFrameEv
__ZN7WebCore14DocumentLoader15detachFromFrameEv
__ZN7WebCore14DocumentLoader18addArchiveResourceEN3WTF10PassRefPtrINS_15ArchiveResourceEEE
Modified: trunk/Source/WebCore/loader/DocumentLoader.cpp (88609 => 88610)
--- trunk/Source/WebCore/loader/DocumentLoader.cpp 2011-06-12 00:51:11 UTC (rev 88609)
+++ trunk/Source/WebCore/loader/DocumentLoader.cpp 2011-06-12 04:19:39 UTC (rev 88610)
@@ -307,7 +307,7 @@
frameLoader->client()->committedLoad(this, data, length);
}
-void DocumentLoader::commitData(const char* bytes, int length)
+void DocumentLoader::commitData(const char* bytes, size_t length)
{
// Set the text encoding. This is safe to call multiple times.
bool userChosen = true;
Modified: trunk/Source/WebCore/loader/DocumentLoader.h (88609 => 88610)
--- trunk/Source/WebCore/loader/DocumentLoader.h 2011-06-12 00:51:11 UTC (rev 88609)
+++ trunk/Source/WebCore/loader/DocumentLoader.h 2011-06-12 04:19:39 UTC (rev 88610)
@@ -238,7 +238,7 @@
// The WebKit layer calls this function when it's ready for the data to
// actually be added to the document.
- void commitData(const char* bytes, int length);
+ void commitData(const char* bytes, size_t length);
#if ENABLE(OFFLINE_WEB_APPLICATIONS)
ApplicationCacheHost* applicationCacheHost() const { return m_applicationCacheHost.get(); }
Modified: trunk/Source/WebCore/loader/DocumentWriter.cpp (88609 => 88610)
--- trunk/Source/WebCore/loader/DocumentWriter.cpp 2011-06-12 00:51:11 UTC (rev 88609)
+++ trunk/Source/WebCore/loader/DocumentWriter.cpp 2011-06-12 04:19:39 UTC (rev 88610)
@@ -198,11 +198,8 @@
m_frame->document()->recalcStyle(Node::Force);
}
-void DocumentWriter::addData(const char* bytes, int length)
+void DocumentWriter::addData(const char* bytes, size_t length)
{
- if (length == -1)
- length = strlen(bytes);
-
m_parser->appendBytes(this, bytes, length);
}
Modified: trunk/Source/WebCore/loader/DocumentWriter.h (88609 => 88610)
--- trunk/Source/WebCore/loader/DocumentWriter.h 2011-06-12 00:51:11 UTC (rev 88609)
+++ trunk/Source/WebCore/loader/DocumentWriter.h 2011-06-12 04:19:39 UTC (rev 88610)
@@ -51,7 +51,7 @@
void begin();
void begin(const KURL&, bool dispatchWindowObjectAvailable = true, SecurityOrigin* forcedSecurityOrigin = 0);
- void addData(const char* bytes, int length = -1);
+ void addData(const char* bytes, size_t length);
void end();
void endIfNotLoadingMainResource();
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes