nsAutoString xmlTopic("xmlparser"); nsIObserverService* anObserverService = nsnull;
if (bXMLEncodingObserverStarted == PR_FALSE) return res;
NS_IMETHODIMP nsXMLEncodingObserver::End() {    nsresult res = NS_OK;    nsAutoString xmlTopic("xmlparser");    nsIObserverService* anObserverService = nsnull;    res = nsServiceManager::GetService(NS_OBSERVERSERVICE_PROGID,                                        nsIObserverService::GetIID(),                                       (nsISupports**) &anObserverService);    if(NS_FAILED(res))         goto done;         res = anObserverService->RemoveObserver(this, xmlTopic.GetUnicode());    nsServiceManager::ReleaseService(NS_OBSERVERSERVICE_PROGID,                                     anObserverService);done:    return res;}