MCPcopy Index your code
hub / github.com/Bitmessage/PyBitmessage / stopThread

Method stopThread

src/class_smtpServer.py:166–179  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

164 self.server = smtpServerPyBitmessage(('127.0.0.1', LISTENPORT), None)
165
166 def stopThread(self):
167 super(smtpServer, self).stopThread()
168 self.server.close()
169 return
170 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
171# for ip in ('127.0.0.1', BMConfigParser().get('bitmessagesettings', 'onionbindip')):
172 for ip in ('127.0.0.1'):
173 try:
174 s.connect((ip, LISTENPORT))
175 s.shutdown(socket.SHUT_RDWR)
176 s.close()
177 break
178 except:
179 pass
180
181 def run(self):
182 asyncore.loop(1)

Callers 1

signalsFunction · 0.45

Calls 2

closeMethod · 0.45
connectMethod · 0.45

Tested by

no test coverage detected