PRUnichar * text = result.ToNewUnicode(); mText.SetTo(text, result.Length()); nsCRT::free(text);
mText.SetTo(result.get(), result.Length());
nsAttributeContent::ValidateTextFragment(){  if (nsnull != mContent) {    nsAutoString result;    mContent->GetAttr(mNameSpaceID, mAttrName, result);    PRUnichar * text = result.ToNewUnicode();    mText.SetTo(text, result.Length());    nsCRT::free(text);  }  else {    mText.SetTo("", 0);  }}