fixed memory leak from prev checkin

git-svn-id: svn://10.0.0.236/trunk@2447 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
karnaze 1998-05-28 00:42:26 +00:00
parent ea64ef1e2e
commit c71fc09344

View File

@ -365,11 +365,13 @@ NS_METHOD nsInputFrame::HandleEvent(nsIPresContext& aPresContext,
// every image button will get every event.
nsIView* view;
GetView(view);
nsInput* content = (nsInput *)mContent;
if (view && (content->GetWidgetSupports() != aEvent->widgetSupports)) {
aEventStatus = nsEventStatus_eIgnore;
if (view) {
NS_RELEASE(view);
return NS_OK;
nsInput* content = (nsInput *)mContent;
if (content->GetWidgetSupports() != aEvent->widgetSupports) {
aEventStatus = nsEventStatus_eIgnore;
return NS_OK;
}
}
switch (aEvent->message) {