Safely stop the thread.
(self)
| 318 | self.start() |
| 319 | |
| 320 | def halt(self): |
| 321 | """Safely stop the thread.""" |
| 322 | if not self.started: |
| 323 | return |
| 324 | |
| 325 | self.stop.set() |
| 326 | os.write(self.writefd, b'\0') # Ensure we're not locked in a read() |
| 327 | self.join() |
| 328 | |
| 329 | class SubprocessStreamCapturePlugin(Plugin): |
| 330 | name='subprocstreams' |