Closed Bug 1461620 Opened 6 years ago Closed 6 years ago

nsGlobalWindowInner::EnableOrientationChangeListener does something weird

Categories

(Core :: DOM: Core & HTML, enhancement)

58 Branch
enhancement
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1433815

People

(Reporter: baku, Unassigned)

Details

https://searchfox.org/mozilla-central/source/dom/base/nsGlobalWindowInner.cpp#6791-6802

  // XXX: mDocShell is never set on the inner window?
  nsIDocShell* docShell = nullptr;
  if (!nsContentUtils::ShouldResistFingerprinting(docShell) &&
      !mOrientationChangeObserver) {

What's the point of calling nsContentUtils::ShouldResistFingerprinting(docShell) with a nullptr?
Nika, can you take a look? This code is from bug 1419597.
Flags: needinfo?(nika)
(In reply to Andrea Marchesini [:baku] from comment #1)
> Nika, can you take a look? This code is from bug 1419597.

That confused comment is written by me. The original source of the code before my massive rewrite also passed in a nullptr, and I wanted to preserve behaviour. I don't _think_ there's any purpose to it... :shrug:
Flags: needinfo?(nika)
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → DUPLICATE
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.