Title: [170263] trunk/Source/WebKit2
- Revision
- 170263
- Author
- [email protected]
- Date
- 2014-06-22 09:47:20 -0700 (Sun, 22 Jun 2014)
Log Message
Address a review comment.
* UIProcess/mac/LegacySessionStateCoding.cpp:
(WebKit::HistoryEntryDataDecoder::markInvalid):
(WebKit::decodeFormDataElement):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (170262 => 170263)
--- trunk/Source/WebKit2/ChangeLog 2014-06-22 16:34:15 UTC (rev 170262)
+++ trunk/Source/WebKit2/ChangeLog 2014-06-22 16:47:20 UTC (rev 170263)
@@ -1,3 +1,11 @@
+2014-06-22 Anders Carlsson <[email protected]>
+
+ Address a review comment.
+
+ * UIProcess/mac/LegacySessionStateCoding.cpp:
+ (WebKit::HistoryEntryDataDecoder::markInvalid):
+ (WebKit::decodeFormDataElement):
+
2014-06-21 Anders Carlsson <[email protected]>
Implement the rest of back forward tree decoding
Modified: trunk/Source/WebKit2/UIProcess/mac/LegacySessionStateCoding.cpp (170262 => 170263)
--- trunk/Source/WebKit2/UIProcess/mac/LegacySessionStateCoding.cpp 2014-06-22 16:34:15 UTC (rev 170262)
+++ trunk/Source/WebKit2/UIProcess/mac/LegacySessionStateCoding.cpp 2014-06-22 16:47:20 UTC (rev 170263)
@@ -329,6 +329,7 @@
}
bool isValid() const { return m_buffer <= m_bufferEnd; }
+ void markInvalid() { m_buffer = m_bufferEnd + 1; }
bool finishDecoding() { return m_buffer == m_bufferEnd; }
@@ -394,8 +395,6 @@
return m_bufferEnd >= alignedPosition && static_cast<size_t>(m_bufferEnd - alignedPosition) >= size;
}
- void markInvalid() { m_buffer = m_bufferEnd + 1; }
-
const uint8_t* m_buffer;
const uint8_t* m_bufferEnd;
};
@@ -441,8 +440,10 @@
decoder >> shouldGenerateFile;
decoder >> formDataElement.fileStart;
- if (formDataElement.fileStart < 0)
+ if (formDataElement.fileStart < 0) {
+ decoder.markInvalid();
return;
+ }
int64_t fileLength;
decoder >> fileLength;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes