content->GetDocument(*getter_AddRefs(doc));
content->GetDocument(getter_AddRefs(doc));
static void GetPrimaryPresShell(nsIFrame* aFrame, nsIPresShell** aResult){  *aResult = nsnull;  if (!aFrame)    return;   nsCOMPtr<nsIDocument> doc;  nsCOMPtr<nsIContent> content;  aFrame->GetContent(getter_AddRefs(content));  content->GetDocument(*getter_AddRefs(doc));  if (doc)    doc->GetShellAt(0, aResult); // Addref happens here.}