diff options
author | astokes <astokes@ef72aa8b-4018-0410-8976-d6e080ef94d8> | 2010-04-12 15:03:22 +0000 |
---|---|---|
committer | astokes <astokes@ef72aa8b-4018-0410-8976-d6e080ef94d8> | 2010-04-12 15:03:22 +0000 |
commit | 34a9bebab8db3961039adc58eb16a586191900bc (patch) | |
tree | 8811352e4af15401a87c86c3a0ecae178be64358 | |
parent | 2456f22f86c4d4367d482989e067d4164165894f (diff) | |
download | sos-34a9bebab8db3961039adc58eb16a586191900bc.tar.gz |
strips new line from hostname
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/sos/trunk@917 ef72aa8b-4018-0410-8976-d6e080ef94d8
-rw-r--r-- | sos.spec | 1 | ||||
-rwxr-xr-x | sos/policyredhat.py | 2 |
2 files changed, 2 insertions, 1 deletions
@@ -52,6 +52,7 @@ rm -rf ${RPM_BUILD_ROOT} * Sun Apr 11 2010 Adam Stokes <ajs at redhat dot com> = 2.0-0 - Bump release to 2 - Fix problem where sos generates error on newline in hostname +- Remove references to sysreport* * Tue Mar 30 2010 Adam Stokes <ajs at redhat dot com> = 1.9-5 - Remove references to rh-upload diff --git a/sos/policyredhat.py b/sos/policyredhat.py index 58ecdd2b..caea9f34 100755 --- a/sos/policyredhat.py +++ b/sos/policyredhat.py @@ -149,7 +149,7 @@ class SosPolicy: return Popen("/bin/uname -r", shell=True, stdout=PIPE, bufsize=-1).stdout.read().strip("\n") def hostName(self): - return Popen("/bin/hostname", shell=True, stdout=PIPE, bufsize=-1).stdout.read().split(".")[0] + return Popen("/bin/hostname", shell=True, stdout=PIPE, bufsize=-1).stdout.read().strip("\n").split(".")[0] def rhelVersion(self): try: |