diff --git a/tsshbatch.py b/tsshbatch.py index 6d31f18..52d5ad7 100755 --- a/tsshbatch.py +++ b/tsshbatch.py @@ -17,7 +17,7 @@ PROGNAME = "tsshbatch.py" BASENAME = PROGNAME.split(".py")[0] PROGENV = BASENAME.upper() -RCSID = "$Id: tsshbatch.py,v 1.135 2013/02/22 18:23:35 tundra Exp $" +RCSID = "$Id: tsshbatch.py,v 1.136 2013/02/22 20:36:23 tundra Exp $" VERSION = RCSID.split()[2] CPRT = "(c)" @@ -57,7 +57,7 @@ # Constants And Literals ##### -FAILURE = "FAILURE" +FAILURE = "FAILURE: " INDENTWIDTH = 8 OPTIONSLIST = "H:ehkn:p:v" PADWIDTH = 30 @@ -183,7 +183,7 @@ sudonoise = "" if sudonoise: - PrintReport([host, FAILURE, eBADSUDO % sudonoise], HANDLER=PrintStderr) + PrintReport([host, FAILURE % (eBADSUDO % sudonoise)], HANDLER=PrintStderr) ssh.close() return @@ -195,12 +195,12 @@ # Catch authentication problems explicitly except paramiko.AuthenticationException: - PrintReport([host, FAILURE, eNOLOGIN], HANDLER=PrintStderr) + PrintReport([host, FAILURE % eNOLOGIN], HANDLER=PrintStderr) # Everything else is some kind of connection problem except: - PrintReport([host, FAILURE, eNOCONNECT % sys.exc_info()[1]], HANDLER=PrintStderr) + PrintReport([host, FAILURE % (eNOCONNECT % sys.exc_info()[1])], HANDLER=PrintStderr) ssh.close()