[Spambayes-checkins] spambayes/windows pop3proxy_service.py, 1.6,
1.7
Tony Meyer
anadelonbrin at users.sourceforge.net
Sun Aug 17 22:52:56 EDT 2003
Update of /cvsroot/spambayes/spambayes/windows
In directory sc8-pr-cvs1:/tmp/cvs-serv19275/windows
Modified Files:
pop3proxy_service.py
Log Message:
Provide a simpler interface to pop3proxy, primarily for the windows service,
but should also be useful for any other users.
Adjust pop3proxy_service to use these, which also means that it will
kick of smtpproxy (if applicable), unlike previously.
Index: pop3proxy_service.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/windows/pop3proxy_service.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** pop3proxy_service.py 20 Jul 2003 07:54:03 -0000 1.6
--- pop3proxy_service.py 18 Aug 2003 04:52:54 -0000 1.7
***************
*** 77,86 ****
def SvcStop(self):
! self.ReportServiceStatus(win32service.SERVICE_STOP_PENDING)
! self.event_stop.set()
def SvcDoRun(self):
# Setup our state etc
! pop3proxy.state.createWorkers()
assert not pop3proxy.state.launchUI, "Service can't launch a UI"
--- 77,85 ----
def SvcStop(self):
! pop3proxy.stop(pop3proxy.state)
def SvcDoRun(self):
# Setup our state etc
! pop3proxy.prepare(state=pop3proxy.state)
assert not pop3proxy.state.launchUI, "Service can't launch a UI"
***************
*** 117,125 ****
def ServerThread(self):
- state = pop3proxy.state
- state.buildServerStrings()
try:
try:
! pop3proxy.main(state.servers, state.proxyPorts, state.uiPort, state.launchUI)
except SystemExit:
# user requested shutdown
--- 116,122 ----
def ServerThread(self):
try:
try:
! pop3proxy.start(pop3proxy.state)
except SystemExit:
# user requested shutdown
***************
*** 139,143 ****
servicemanager.LogErrorMsg(message)
finally:
! self.SvcStop()
if __name__=='__main__':
--- 136,141 ----
servicemanager.LogErrorMsg(message)
finally:
! self.ReportServiceStatus(win32service.SERVICE_STOP_PENDING)
! self.event_stop.set()
if __name__=='__main__':
More information about the Spambayes-checkins
mailing list