if (!UrlToGoTo) { return; }      if (UrlToGoTo.indexOf("http") != 0) { Components.utils.reportError ("launchBrowser: " + "Invalid URL provided: " + UrlToGoTo + " Only http: return; }  
function launchBrowser(UrlToGoTo){  // 1. try to get (most recent) browser window, in case in browser app.  var navWindow;  try {    var wm = (Components              .classes["@mozilla.org/appshell/window-mediator;1"]              .getService(Components.interfaces.nsIWindowMediator));    navWindow = wm.getMostRecentWindow("navigator:browser");  } catch (e) {    dump("launchBrowser (getMostRecentWindow) exception:\n" + e + "\n");  }  if (navWindow) {    if ("delayedOpenTab" in navWindow)      navWindow.delayedOpenTab(UrlToGoTo);    else if ("loadURI" in navWindow)      navWindow.loadURI(UrlToGoTo);    else      navWindow.content.location.href = UrlToGoTo;    return;  }  // 2. try a new browser window, in case in suite (seamonkey)  var messenger;  try {    var messenger = (Components                     .classes["@mozilla.org/messenger;1"]                     .createInstance());    messenger = messenger.QueryInterface(Components.interfaces.nsIMessenger);  } catch (e) {    dump("launchBrowser (messenger) exception:\n"+e+"\n");  }  if (messenger) {    messenger.launchExternalURL(UrlToGoTo);      return;  }   // 3. try an external app, in case not in a browser app (SB, TB, etc).  var externalLoader =    (Components     .classes["@mozilla.org/uriloader/external-protocol-service;1"]     .getService(Components.interfaces.nsIExternalProtocolService));  var nsURI = (Components               .classes["@mozilla.org/network/io-service;1"]               .getService(Components.interfaces.nsIIOService)               .newURI(UrlToGoTo, null, null));  externalLoader.loadUrl(nsURI);}
5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/5872/871e532d4d720d86f7617b6a435e7c2647f4dab2/applicationUtil.js/buggy/calendar/resources/content/applicationUtil.js