Bug 1333001. Ensure that ImportRule in fact always has a non-null mMedia. r=heycam

This commit is contained in:
Boris Zbarsky
2017-01-24 10:02:46 -05:00
parent 441f1fa5bc
commit 809fc1de39

View File

@@ -271,6 +271,10 @@ ImportRule::ImportRule(const ImportRule& aCopy)
aCopy.mChildSheet->Clone(nullptr, this, nullptr, nullptr);
SetSheet(sheet);
// SetSheet sets mMedia appropriately
} else {
// We better just copy mMedia from aCopy, since we have nowhere else to get
// one.
mMedia = aCopy.mMedia;
}
}