2019-08-26 Fred Gleason <fredg@paravelsystems.com>

* Fixed a bug in the 'pypad_liqcomp.py' PyPAD script that caused
	an infinite loop.
This commit is contained in:
Fred Gleason 2019-08-27 17:51:35 -04:00
parent 533b760cd1
commit 42c91a7cfd
2 changed files with 17 additions and 16 deletions

View File

@ -18991,3 +18991,6 @@
* Fixed a bug in rdadmin(1) that allowed more than one PyPAD
instance to be selected at a time in the 'List PyPAD Instances'
dialog.
2019-08-26 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in the 'pypad_liqcomp.py' PyPAD script that caused
an infinite loop.

View File

@ -37,9 +37,8 @@ def ProcessPad(update):
last_updates[update.machine()]=None
n=1
while(True):
section='System'+str(n)
try:
while(update.config().has_section(section)):
if update.shouldBeProcessed(section) and update.hasPadType(pypad.TYPE_NOW) and (last_updates[update.machine()] != update.startDateTimeString(pypad.TYPE_NOW)):
last_updates[update.machine()]=update.startDateTimeString(pypad.TYPE_NOW)
title=update.resolvePadFields(update.config().get(section,'Title'),pypad.ESCAPE_NONE)
@ -52,8 +51,7 @@ def ProcessPad(update):
send_sock.sendto(msg.encode('utf-8'),
(update.config().get(section,'IpAddress'),int(update.config().get(section,'UdpPort'))))
n=n+1
except configparser.NoSectionError:
return
section='System'+str(n)
#
# 'Main' function