NS_IF_RELEASE(frameType);
nsTableFrame::GetFrameAtOrBefore(nsIPresContext* aPresContext,                                 nsIFrame*       aParentFrame,                                 nsIFrame*       aPriorChildFrame,                                 nsIAtom*        aChildType){  nsIFrame* result = nsnull;  if (!aPriorChildFrame) {    return result;  }  nsIAtom* frameType;  aPriorChildFrame->GetFrameType(&frameType);  if (aChildType == frameType) {    NS_RELEASE(frameType);    return (nsTableCellFrame*)aPriorChildFrame;  }  NS_IF_RELEASE(frameType);  // aPriorChildFrame is not of type aChildType, so we need start from   // the beginnng and find the closest one   nsIFrame* childFrame;  nsIFrame* lastMatchingFrame = nsnull;  aParentFrame->FirstChild(aPresContext, nsnull, &childFrame);  while (childFrame && (childFrame != aPriorChildFrame)) {    childFrame->GetFrameType(&frameType);    if (aChildType == frameType) {      lastMatchingFrame = childFrame;    }    NS_IF_RELEASE(frameType);    childFrame->GetNextSibling(&childFrame);  }  return (nsTableCellFrame*)lastMatchingFrame;}