summaryrefslogtreecommitdiffstats
path: root/image.py
diff options
context:
space:
mode:
authorPaul Nasrat <pnasrat@redhat.com>2005-11-15 02:43:34 +0000
committerPaul Nasrat <pnasrat@redhat.com>2005-11-15 02:43:34 +0000
commitc7f542f61836d6a79837bb3a38ba93793d99e1ba (patch)
tree6d1f83e60d564c4d1487e28f8ad751667a0037ef /image.py
parent95e2b35eb224d50525d17756f3e59b1b3179f1b5 (diff)
downloadanaconda-c7f542f61836d6a79837bb3a38ba93793d99e1ba.tar.gz
anaconda-c7f542f61836d6a79837bb3a38ba93793d99e1ba.tar.xz
anaconda-c7f542f61836d6a79837bb3a38ba93793d99e1ba.zip
Change getRPMFileName signature, use in callback
Diffstat (limited to 'image.py')
-rw-r--r--image.py18
1 files changed, 9 insertions, 9 deletions
diff --git a/image.py b/image.py
index 94841cd70..ecdd738cb 100644
--- a/image.py
+++ b/image.py
@@ -98,11 +98,11 @@ class ImageInstallMethod(InstallMethod):
def getFilename(self, filename, callback=None, destdir=None, retry=1):
return self.tree + "/" + filename
- def getRPMFilename(self, h, timer, callback=None):
+ def getRPMFilename(self, filename, h, timer, callback=None):
if self.currentIso is not None and self.currentIso != h[1000002]:
log.info("switching from iso %s to %s for %s-%s-%s.%s" %(self.currentIso, h[1000002], h['name'], h['version'], h['release'], h['arch']))
self.currentIso = h[1000002]
- return self.getFilename("/%s/RPMS/%s" % (productPath, h[1000000]), callback=callback)
+ return self.getFilename("/%s/RPMS/%s" % (productPath,filename), callback=callback)
def getSourcePath(self):
return self.tree
@@ -184,10 +184,10 @@ class CdromInstallMethod(ImageInstallMethod):
def getFilename(self, filename, callback=None, destdir=None, retry=1):
return self.tree + "/" + filename
- def getRPMFilename(self, h, timer, callback=None):
+ def getRPMFilename(self, filename, h, timer, callback=None):
if h[1000002] == None or 1000002 not in h.keys():
log.warning("header for %s has no disc location tag, assuming it's"
- "on the current CD" %(h[1000000],))
+ "on the current CD" %(filename,))
elif h[1000002] not in self.currentDisc:
timer.stop()
log.info("switching from iso %s to %s for %s-%s-%s.%s" %(self.currentDisc, h[1000002], h['name'], h['version'], h['release'], h['arch']))
@@ -328,8 +328,8 @@ class CdromInstallMethod(ImageInstallMethod):
while tries < 5:
try:
shutil.copy("%s/%s/RPMS/%s" % (self.tree, productPath,
- h[1000000]),
- tmppath + h[1000000])
+ filename),
+ tmppath + filename
except IOError, (errnum, msg):
log.critical("IOError %s occurred copying %s: %s",
errnum, h[1000000], str(msg))
@@ -341,7 +341,7 @@ class CdromInstallMethod(ImageInstallMethod):
if tries >= 5:
raise FileCopyException
- return tmppath + h[1000000]
+ return tmppath + filename
def unlinkFilename(self, fullName):
os.remove(fullName)
@@ -489,13 +489,13 @@ class NfsIsoInstallMethod(NfsInstallMethod):
def getFilename(self, filename, callback=None, destdir=None, retry=1):
return self.mntPoint + "/" + filename
- def getRPMFilename(self, h, timer, callback=None):
+ def getRPMFilename(self, filename, h, timer, callback=None):
if self.imageMounted != h[1000002]:
log.info("switching from iso %s to %s for %s-%s-%s.%s" %(self.imageMounted, h[1000002], h['name'], h['version'], h['release'], h['arch']))
self.umountImage()
self.mountImage(h[1000002])
- return self.getFilename("/%s/RPMS/%s" % (productPath, h[1000000]))
+ return self.getFilename("/%s/RPMS/%s" % (productPath, filename))
def umountImage(self):
if self.imageMounted: