if (mRangeArray) { PRUint32 cnt; nsresult rv = mRangeArray->Count(&cnt); if (NS_FAILED(rv)) return rv; *aRangeCount = cnt; } else { *aRangeCount = 0; }
*aRangeCount = mRangeArray.Count();
nsTypedSelection::GetRangeCount(PRInt32* aRangeCount){  if (!aRangeCount) 		return NS_ERROR_NULL_POINTER;	if (mRangeArray)	{		PRUint32 cnt;    nsresult rv = mRangeArray->Count(&cnt);    if (NS_FAILED(rv)) return rv;    *aRangeCount = cnt;	}	else	{		*aRangeCount = 0;	}		return NS_OK;}