diff options
author | Bill Nottingham <notting@redhat.com> | 2007-12-05 17:40:34 -0500 |
---|---|---|
committer | Bill Nottingham <notting@redhat.com> | 2007-12-07 13:24:34 -0500 |
commit | d2f5be7dae402d2781b22dce3bd0d59389586729 (patch) | |
tree | 4ee3706732ec56676c0a2cc181ded3fc71df4497 /isys/isys.py | |
parent | 7ec3ee57ca26c7d4fdb29d102deb6cadf79bc04d (diff) | |
download | anaconda-d2f5be7dae402d2781b22dce3bd0d59389586729.tar.gz anaconda-d2f5be7dae402d2781b22dce3bd0d59389586729.tar.xz anaconda-d2f5be7dae402d2781b22dce3bd0d59389586729.zip |
Get out of the business of creating device nodes.
Diffstat (limited to 'isys/isys.py')
-rwxr-xr-x[-rw-r--r--] | isys/isys.py | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/isys/isys.py b/isys/isys.py index 2519db034..170d5e126 100644..100755 --- a/isys/isys.py +++ b/isys/isys.py @@ -598,30 +598,6 @@ def getDasdState(dev): return 0 -## Create a device node. -# This method creates a device node, optionally in a directory tree other than -# /dev. Do not create device nodes in /tmp as we are trying to move away from -# using /tmp for anything other than temporary data. -# -# @param name The basename of the device node. -# @param fn An optional directory to create the new device node in. -# @return The path of the created device node. -def makeDevInode(name, fn=None): - if fn: - if fn.startswith("/tmp"): - warnings.warn("device node created in /tmp", stacklevel=2) - if os.path.exists(fn): - return fn - _isys.mkdevinode(name, fn) - return fn - path = '/dev/%s' % (name,) - try: - os.stat(path) - except OSError: - path = '/dev/%s' % (name,) - _isys.mkdevinode(name, path) - return path - ## Calculate the broadcast address of a network. # @param ip An IPv4 address as a string. # @param nm A corresponding netmask as a string. |