char * folderRoot;
char * folderRoot=nsnull;
void nsMessenger::InitializeFolderRoot(){    nsresult rv;    	// get the current identity from the mail session....    NS_WITH_SERVICE(nsIMsgMailSession, mailSession, kCMsgMailSessionCID, &rv);    if (NS_FAILED(rv)) return;    nsCOMPtr<nsIMsgIncomingServer> server;    rv = mailSession->GetCurrentServer(getter_AddRefs(server));        char * folderRoot;    if (NS_SUCCEEDED(rv))        rv = server->GetLocalPath(&folderRoot);        if (NS_SUCCEEDED(rv)) {        // everyone should have a inbox so let's        // tack that folder name on to the root path...        m_folderPath = folderRoot;        m_folderPath += "Inbox";		PR_FREEIF(folderRoot);    } // if we have a folder root for the current server        // create Undo/Redo Transaction Manager    NS_WITH_SERVICE (nsIComponentManager, compMgr, kComponentManagerCID, &rv);    if (NS_SUCCEEDED(rv))    {      rv = compMgr->CreateInstance(kTransactionManagerCID, nsnull,                                    nsITransactionManager::GetIID(),                                   getter_AddRefs(mTxnMgr));      if (NS_SUCCEEDED(rv))        mTxnMgr->SetMaxTransactionCount(-1);    }}