mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
Fix for 2161 -- if nsView::GetViewFor() is called with a null widget, just return a null view.
This commit is contained in:
parent
d798c3e079
commit
6b37d2bc99
@ -178,7 +178,7 @@ nsIView* nsView::GetViewFor(nsIWidget* aWidget)
|
||||
NS_PRECONDITION(nsnull != aWidget, "null widget ptr");
|
||||
|
||||
// The widget's client data points back to the owning view
|
||||
if (NS_SUCCEEDED(aWidget->GetClientData(clientData))) {
|
||||
if (aWidget && NS_SUCCEEDED(aWidget->GetClientData(clientData))) {
|
||||
view = (nsIView*)clientData;
|
||||
|
||||
if (nsnull != view) {
|
||||
|
Loading…
Reference in New Issue
Block a user