fix some alt_host issues

This commit is contained in:
David Rose 2009-11-05 02:59:52 +00:00
parent 5843771931
commit 573d69caf5

View File

@ -292,6 +292,9 @@ class AppRunner(DirectObject):
than the one given, for instance to download a version in
testing. """
if hostUrl is None:
hostUrl = PandaSystem.getPackageHostUrl()
altUrl = self.altHostMap.get(hostUrl, None)
if altUrl:
# We got an alternate host. Use it.
@ -617,6 +620,11 @@ class AppRunner(DirectObject):
if self.p3dPackage:
self.p3dConfig = self.p3dPackage.FirstChildElement('config')
xhost = self.p3dPackage.FirstChildElement('host')
while xhost:
self.__readHostXml(xhost)
xhost = xhost.NextSiblingElement('host')
if self.p3dConfig:
allowPythonDev = self.p3dConfig.Attribute('allow_python_dev')
if allowPythonDev:
@ -625,11 +633,6 @@ class AppRunner(DirectObject):
if guiApp:
self.guiApp = int(guiApp)
xhost = self.p3dConfig.FirstChildElement('host')
while xhost:
self.__readHostXml(xhost)
xhost = xhost.NextSiblingElement('host')
# The interactiveConsole flag can only be set true if the
# application has allow_python_dev set.
if not self.allowPythonDev and interactiveConsole: