Chromium Code Reviews| Index: third_party/WebKit/Source/core/fetch/ScriptResource.cpp |
| diff --git a/third_party/WebKit/Source/core/fetch/ScriptResource.cpp b/third_party/WebKit/Source/core/fetch/ScriptResource.cpp |
| index 50935706761b2a9ed2ec6e79fe6cfd3d62aa4e04..36b5abb027d1f5aa0f8f6eb4b4642a2018c6a132 100644 |
| --- a/third_party/WebKit/Source/core/fetch/ScriptResource.cpp |
| +++ b/third_party/WebKit/Source/core/fetch/ScriptResource.cpp |
| @@ -77,7 +77,7 @@ AtomicString ScriptResource::mimeType() const |
| return extractMIMETypeFromMediaType(m_response.httpHeaderField("Content-Type")).lower(); |
| } |
| -const String& ScriptResource::script() |
| +RefPtrWillBeRawPtr<CompressableString> ScriptResource::script() |
|
haraken
2015/10/22 16:03:31
RefPtrWillBeRawPtr<CompressableString> => Compress
hajimehoshi
2015/10/26 09:34:02
Done.
|
| { |
| ASSERT(!isPurgeable()); |
| ASSERT(isLoaded()); |
| @@ -89,10 +89,10 @@ const String& ScriptResource::script() |
| // That's because the MemoryCache thinks that it can clear out decoded data by calling destroyDecodedData(), |
| // but we can't destroy script in destroyDecodedData because that's our only copy of the data! |
| setEncodedSize(script.sizeInBytes()); |
| - m_script = AtomicString(script); |
| + m_script = CompressableString::create(script); |
| } |
| - return m_script.string(); |
| + return m_script; |
|
haraken
2015/10/22 16:03:31
return m_script.get();
hajimehoshi
2015/10/26 09:34:02
Done.
|
| } |
| bool ScriptResource::mimeTypeAllowedByNosniff() const |