summaryrefslogtreecommitdiffstats
path: root/command-stubs/list-harddrives-stub
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2008-01-29 14:31:55 -0500
committerChris Lumens <clumens@redhat.com>2008-01-29 14:31:55 -0500
commit3335f2e37cf3c969ae7e3d68283f144459973441 (patch)
tree83e84af9161c45a3eabcddebe690ffb2cdad7ac7 /command-stubs/list-harddrives-stub
parent553f494dea845b8d3ae30af5977619ad05084af2 (diff)
downloadanaconda-3335f2e37cf3c969ae7e3d68283f144459973441.tar.gz
anaconda-3335f2e37cf3c969ae7e3d68283f144459973441.tar.xz
anaconda-3335f2e37cf3c969ae7e3d68283f144459973441.zip
Remove the last references to makeDevInode (#430784).
Diffstat (limited to 'command-stubs/list-harddrives-stub')
-rwxr-xr-xcommand-stubs/list-harddrives-stub10
1 files changed, 4 insertions, 6 deletions
diff --git a/command-stubs/list-harddrives-stub b/command-stubs/list-harddrives-stub
index 73f86c2e6..d5c88a76a 100755
--- a/command-stubs/list-harddrives-stub
+++ b/command-stubs/list-harddrives-stub
@@ -36,26 +36,24 @@ drives = isys.hardDriveDict()
driveList = drives.keys()
driveList.sort()
-for drive in driveList:
+for drive in driveList:
if not isys.mediaPresent(drive):
continue
# try to open and get size
skip = 0
- deviceFile = "/tmp/%s" % (drive,)
- isys.makeDevInode(drive, deviceFile)
+ deviceFile = "/dev/%s" % (drive,)
+
try:
dev = parted.PedDevice.get(deviceFile)
except:
skip = 1
- os.remove(deviceFile)
if skip:
continue
sizeMB = (float(dev.heads * dev.cylinders * dev.sectors) / (1024 * 1024)
* dev.sector_size)
-
- print drive, sizeMB
+ print drive, sizeMB