if (NS_FAILED(current->GetParent(*getter_AddRefs(parent))))
if (NS_FAILED(current->GetParent(getter_AddRefs(parent))))
nsresult nsContentIterator::RebuildIndexStack(){  // Make sure we start at the right indexes on the stack!  Build array up  // to common parent of start and end.  Perhaps it's too many entries, but  // thats far better than too few.  nsCOMPtr<nsIContent> parent;  nsCOMPtr<nsIContent> current;  PRInt32              indx;  mIndexes.Clear();  current = mCurNode;  while (current && current != mCommonParent)  {    if (NS_FAILED(current->GetParent(*getter_AddRefs(parent))))      return NS_ERROR_FAILURE;    if (!parent || NS_FAILED(parent->IndexOf(current, indx)))      return NS_ERROR_FAILURE;      mIndexes.InsertElementAt(NS_INT32_TO_PTR(indx),0);    current = parent;  }  return NS_OK;}