#517: a couple tune-ups

This commit is contained in:
Cameron Kaiser 2018-08-18 16:33:55 -07:00
parent 0bbf06ea62
commit 5f47da2304
2 changed files with 6 additions and 3 deletions

View File

@ -1168,10 +1168,10 @@ Element::GetDestinationInsertionPoints()
void
Element::GetAttribute(const nsAString& aName, DOMString& aReturn)
{
// Complete the illusion of issue 517 by preventing Rocket Loader from
// seeing the data-cf-nonce attribute. This doesn't seem to be used
// Complete the illusion of TenFourFox issue 517 by preventing Rocket Loader
// from seeing the data-cf-nonce attribute. This doesn't seem to be used
// anywhere else in the Cloudflare stack.
if (MOZ_UNLIKELY(aName.LowerCaseEqualsASCII("data-cf-nonce"))) {
if (!IsXULElement() && MOZ_UNLIKELY(aName.LowerCaseEqualsASCII("data-cf-nonce"))) {
#if DEBUG
fprintf(stderr, "TenFourFox: blocked access to proscribed property data-cf-nonce.\n");
#endif

View File

@ -522,11 +522,14 @@ EventStateManager::PreHandleEvent(nsPresContext* aPresContext,
return NS_ERROR_NULL_POINTER;
}
#if(0)
// This is obnoxious, and seems to no longer be relevant.
NS_WARN_IF_FALSE(!aTargetFrame ||
!aTargetFrame->GetContent() ||
aTargetFrame->GetContent() == aTargetContent ||
aTargetFrame->GetContent()->GetFlattenedTreeParent() == aTargetContent,
"aTargetFrame should be related with aTargetContent");
#endif
mCurrentTarget = aTargetFrame;
mCurrentTargetContent = nullptr;