summaryrefslogtreecommitdiffstats
path: root/harddrive.py
diff options
context:
space:
mode:
authorMatt Wilson <msw@redhat.com>1999-09-22 04:25:53 +0000
committerMatt Wilson <msw@redhat.com>1999-09-22 04:25:53 +0000
commit7e5ed90aa9fba82756569d22667e5829056e0c59 (patch)
tree75922bd551389e5930c371f62cb8d84cd92547ae /harddrive.py
parentaa2dec51248af6a388509b1b83909070ea733d4b (diff)
downloadanaconda-7e5ed90aa9fba82756569d22667e5829056e0c59.tar.gz
anaconda-7e5ed90aa9fba82756569d22667e5829056e0c59.tar.xz
anaconda-7e5ed90aa9fba82756569d22667e5829056e0c59.zip
no gurantee on suffix - do a copy onto msdos filesytem from linux and you don't get .rpm
Diffstat (limited to 'harddrive.py')
-rw-r--r--harddrive.py17
1 files changed, 11 insertions, 6 deletions
diff --git a/harddrive.py b/harddrive.py
index 62914331a..2738bf841 100644
--- a/harddrive.py
+++ b/harddrive.py
@@ -30,12 +30,17 @@ class InstallMethod:
hl = []
path = "/tmp/hdimage" + self.path + "/RedHat/RPMS"
for n in os.listdir(path):
- if (n[len(n) - 4:] == '.rpm'):
- fd = os.open(path + "/" + n, 0)
- (h, isSource) = rpm.headerFromPackage(fd)
- self.fnames[h] = n
- hl.append(h)
- os.close(fd)
+# no gurantee on suffix - do a copy onto msdos filesytem from
+# linux and you don't get .rpm
+# if (n[len(n) - 4:] == '.rpm'):
+ fd = os.open(path + "/" + n, 0)
+ try:
+ (h, isSource) = rpm.headerFromPackage(fd)
+ except:
+ continue
+ self.fnames[h] = n
+ hl.append(h)
+ os.close(fd)
isys.umount("/tmp/hdimage")
return HeaderList(hl)