From: Scott Baker Date: Wed, 20 Apr 2011 16:25:21 +0000 (+0000) Subject: fix error output X-Git-Tag: Mom-2.3-3~3 X-Git-Url: http://git.onelab.eu/?p=mom.git;a=commitdiff_plain;h=84d010124e01c6d71f2778daabb3e5adf66437c9 fix error output --- diff --git a/swapmon.py b/swapmon.py index 1076261..ac133fb 100755 --- a/swapmon.py +++ b/swapmon.py @@ -171,7 +171,7 @@ def slicestat(names = None): # Represent process as a dict of fields values = line.split(None, len(fields) - 1) if len(values) != len(fields): - print "slicestat: failed to parse line:", line + print "slicestat: failed to parse line: " + line continue proc = dict(zip(fields, values)) @@ -185,12 +185,12 @@ def slicestat(names = None): except ValueError: pass - # vps sometimes prints ERR or the name of the slice + # vps sometimes prints ERR or the name of the slice # instead of a context ID if it # cannot identify the context of an orphaned (usually dying) # process. Skip these processes. if (type(proc['xid']) != int) or (type(proc['vsize']) !=int): - print "slicestat: failed to parse line:", line + print "slicestat: failed to parse line: " + line continue # Assign (pl_)sshd processes to slice instead of root