WebKit Bugzilla
Attachment 341235 Details for
Bug 185964
: Avoid doing unnecessary work in Document::shouldEnforceContentDispositionAttachmentSandbox() when setting is disabled
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-185964-20180524170017.patch (text/plain), 1.96 KB, created by
Chris Dumez
on 2018-05-24 17:00:17 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Chris Dumez
Created:
2018-05-24 17:00:17 PDT
Size:
1.96 KB
patch
obsolete
>Subversion Revision: 232166 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index fb8022e3c44eed8843f989514e331560eabe97ce..202162c2a76e5b4437abf028d83daf2c5d076ebd 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,13 @@ >+2018-05-24 Chris Dumez <cdumez@apple.com> >+ >+ Avoid doing unnecessary work in Document::shouldEnforceContentDispositionAttachmentSandbox() when setting is disabled >+ https://bugs.webkit.org/show_bug.cgi?id=185964 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * dom/Document.cpp: >+ (WebCore::Document::shouldEnforceContentDispositionAttachmentSandbox const): >+ > 2018-05-24 Chris Dumez <cdumez@apple.com> > > Some of the work in initializeLogChannelsIfNecessary() is unnecessary for release builds >diff --git a/Source/WebCore/dom/Document.cpp b/Source/WebCore/dom/Document.cpp >index a321e8725d075b71ca0b209ec3c958269bf9e282..dbc338d7fb28f4b3f3dda2cf52e1fe2ecdceea4e 100644 >--- a/Source/WebCore/dom/Document.cpp >+++ b/Source/WebCore/dom/Document.cpp >@@ -7304,15 +7304,15 @@ void Document::applyQuickLookSandbox() > > bool Document::shouldEnforceContentDispositionAttachmentSandbox() const > { >- if (m_isSynthesized) >+ if (!settings().contentDispositionAttachmentSandboxEnabled()) > return false; > >- bool contentDispositionAttachmentSandboxEnabled = settings().contentDispositionAttachmentSandboxEnabled(); >- bool responseIsAttachment = false; >- if (DocumentLoader* documentLoader = m_frame ? m_frame->loader().activeDocumentLoader() : nullptr) >- responseIsAttachment = documentLoader->response().isAttachment(); >+ if (m_isSynthesized) >+ return false; > >- return contentDispositionAttachmentSandboxEnabled && responseIsAttachment; >+ if (auto* documentLoader = m_frame ? m_frame->loader().activeDocumentLoader() : nullptr) >+ return documentLoader->response().isAttachment(); >+ return false; > } > > void Document::applyContentDispositionAttachmentSandbox()
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185964
: 341235