Kaydet (Commit) b8c7b9f0 authored tarafından Andrew M. Kuchling's avatar Andrew M. Kuchling

Translate spaces in the machine name to underscores

    (Power Macintosh -> Power_Macintosh)
üst 1772f176
......@@ -40,10 +40,11 @@ def get_platform ():
(osname, host, release, version, machine) = os.uname()
# Convert the OS name to lowercase and remove '/' characters
# (to accommodate BSD/OS)
# Convert the OS name to lowercase, remove '/' characters
# (to accommodate BSD/OS), and translate spaces (for "Power Macintosh")
osname = string.lower(osname)
osname = string.replace(osname, '/', '')
machine = string.replace(machine, ' ', '_')
if osname[:5] == "linux":
# At least on Linux/Intel, 'machine' is the processor --
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment