From e29fb0bc7934734044eedda32cb2e1244a056fce Mon Sep 17 00:00:00 2001 From: sidya82 Date: Mon, 3 Mar 2014 13:55:30 +0100 Subject: [PATCH] =?UTF-8?q?=09modifi=C3=A9:=20=20=20=20=20=20=20=20=20m/lo?= =?UTF-8?q?g.py=20=09modifi=C3=A9:=20=20=20=20=20=20=20=20=20m/login.py=20?= =?UTF-8?q?=09modifi=C3=A9:=20=20=20=20=20=20=20=20=20superTornado.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- m/log.py | 12 ++++++------ m/login.py | 2 +- superTornado.py | 10 +++++----- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/m/log.py b/m/log.py index bbc6e22..6f60771 100644 --- a/m/log.py +++ b/m/log.py @@ -31,17 +31,17 @@ class Log(object): def printL(self,pMsg,pLvl): self.logger.log(pLvl,pMsg) if pLvl == 10 : - print bcolors.DEBUG, + print bcolors.DEBUG elif pLvl == 20 : - print bcolors.INFO, + print bcolors.INFO elif pLvl == 25 : - print bcolors.SUCCESS, + print bcolors.SUCCESS elif pLvl == 30 : - print bcolors.WARNING, + print bcolors.WARNING elif pLvl == 40 : - print bcolors.FAIL, + print bcolors.FAIL print pMsg - print bcolors.ENDC, + print bcolors.ENDC class bcolors: DEBUG = '\033[94m' diff --git a/m/login.py b/m/login.py index a1208c6..e9fb5d4 100644 --- a/m/login.py +++ b/m/login.py @@ -8,7 +8,7 @@ class Login(object): with open("m/fichier/autorise", "r") as source : for ligne in source : data = ligne.rstrip('\n\r').split(',') - if data[0] in pLog : + if data[0] == pLog : if data[1] in hashMdp : source.close() return True diff --git a/superTornado.py b/superTornado.py index dd43b75..2323e91 100644 --- a/superTornado.py +++ b/superTornado.py @@ -174,12 +174,12 @@ if __name__ == "__main__": sys.exit(1) print log.printL("->Configuration Server Load Successfully !",25) if blind == True: - log.printL(" ->Blind unhabitant",25) + log.printL(" ->Blind unhabitant",20) else : - log.printL(" ->Not blind unhabitant",25) - log.printL(" ->Ip camera : " + ipCamera,25) - log.printL(" ->Port Camera : " + portCamera,25) - log.printL(" ->Port Server : " + portServ,25) + log.printL(" ->Not blind unhabitant",20) + log.printL(" ->Ip camera : " + ipCamera,20) + log.printL(" ->Port Camera : " + portCamera,20) + log.printL(" ->Port Server : " + portServ,20) try : log.printL("->Server Start ...",20)