Merge pull request #8087 from neersighted/string_version

Fix hostname when get_distribution_version() returns a string.
This commit is contained in:
Michael DeHaan 2014-07-28 11:24:58 -04:00
commit 628d828876

View file

@ -190,8 +190,11 @@ def get_distribution_version():
except:
# FIXME: MethodMissing, I assume?
distribution_version = platform.dist()[1]
if type(distribution_version) == str:
distribution_version = 0
else:
distribution_version = None
distribution_version = 0
return distribution_version
def load_platform_subclass(cls, *args, **kwargs):