https://bugs.webkit.org/show_bug.cgi?id=134117
Unreproducible crashes under WebCore::ScrollingTree::updateTreeFromStateNode() 
from messaging a deleted Obj-C object
-and corresponding-
<rdar://problem/17149252>

Reviewed by Simon Fraser.

This is a speculative fix. It makes LayerRepresentation retain m_platformLayer.

* WebCore.exp.in:
* page/scrolling/ScrollingStateNode.h:
(WebCore::LayerRepresentation::LayerRepresentation):
(WebCore::LayerRepresentation::~LayerRepresentation):
(WebCore::LayerRepresentation::operator=):
(WebCore::LayerRepresentation::operator==):
(WebCore::LayerRepresentation::operator ==): Deleted.

Make this ASSERT an ASSERT_WITH_SECURITY_IMPLICATION
* page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::updateTreeFromStateNode):

Moved ScrollingStateNodeMac.mm, which was empty anyway, to cocoa/
ScrollingStateNode.mm so that iOS can use it too.
* page/scrolling/cocoa: Added.
* page/scrolling/cocoa/ScrollingStateNode.mm: Copied from page/scrolling/mac/ScrollingStateNodeMac.mm.

Actual implementation for retain and release.
(WebCore::LayerRepresentation::retainPlatformLayer):
(WebCore::LayerRepresentation::releasePlatformLayer):

Deleted.
* page/scrolling/mac/ScrollingStateNodeMac.mm: Removed.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170224 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Implement more of LegacySessionStateDecoder
https://bugs.webkit.org/show_bug.cgi?id=134144

Reviewed by Sam Weinig.

* Shared/SessionState.cpp:
(WebKit::BackForwardListState::encode):
(WebKit::SessionState::encode): Deleted.
* Shared/SessionState.h:
* UIProcess/mac/LegacySessionStateCoding.cpp:
(WebKit::LegacySessionStateDecoder::decodeSessionState):
(WebKit::LegacySessionStateDecoder::decodeSessionHistory):
(WebKit::LegacySessionStateDecoder::decodeV0SessionHistory):
(WebKit::LegacySessionStateDecoder::decodeV1SessionHistory):
(WebKit::LegacySessionStateDecoder::decodeSessionHistoryEntries):
(WebKit::LegacySessionStateDecoder::decodeSessionHistoryEntry):
* UIProcess/mac/LegacySessionStateCoding.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170225 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Implement more of LegacySessionStateDecoder
https://bugs.webkit.org/show_bug.cgi?id=134145

Reviewed by Sam Weinig.

* Shared/SessionState.h:
* UIProcess/mac/LegacySessionStateCoding.cpp:
(WebKit::LegacySessionStateDecoder::decodeSessionHistoryEntry):
(WebKit::HistoryEntryDataDecoder::HistoryEntryDataDecoder):
(WebKit::HistoryEntryDataDecoder::finishDecoding):
(WebKit::LegacySessionStateDecoder::decodeSessionHistoryEntryData):
* UIProcess/mac/LegacySessionStateCoding.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170226 268f45cc-cd09-0410-ab3c-d52691b4dbfc