mirror of
https://github.com/Pardus-LiderAhenk/ahenk
synced 2024-11-22 15:32:19 +03:00
registration attemp
This commit is contained in:
parent
4bec8505cd
commit
a9395cc911
2 changed files with 3 additions and 9 deletions
|
@ -162,13 +162,7 @@ class AhenkDaemon(BaseDaemon):
|
||||||
print("Registation attemp")
|
print("Registation attemp")
|
||||||
max_attempt_number -= 1
|
max_attempt_number -= 1
|
||||||
self.logger.debug('Ahenk is not registered. Attempting for registration')
|
self.logger.debug('Ahenk is not registered. Attempting for registration')
|
||||||
#registration.registration_request()
|
registration.registration_request()
|
||||||
|
|
||||||
if registration.registration_request() == False:
|
|
||||||
if max_attempt_number < 0:
|
|
||||||
self.registration_failed()
|
|
||||||
else:
|
|
||||||
registration.registration_request()
|
|
||||||
|
|
||||||
#if max_attempt_number < 0:
|
#if max_attempt_number < 0:
|
||||||
# self.logger.warning('Number of Attempting for registration is over')
|
# self.logger.warning('Number of Attempting for registration is over')
|
||||||
|
|
|
@ -120,8 +120,8 @@ class AnonymousMessenger(ClientXMPP):
|
||||||
self.logger.info('Disconnecting...')
|
self.logger.info('Disconnecting...')
|
||||||
self.disconnect()
|
self.disconnect()
|
||||||
self.logger.info('Rebooting...')
|
self.logger.info('Rebooting...')
|
||||||
System.Process.kill_by_pid(int(System.Ahenk.get_pid_number()))
|
#System.Process.kill_by_pid(int(System.Ahenk.get_pid_number()))
|
||||||
sys.exit(2)
|
#sys.exit(2)
|
||||||
Util.shutdown();
|
Util.shutdown();
|
||||||
|
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
|
Loading…
Reference in a new issue