Cleanup when deleted
(self)
| 774 | return |
| 775 | |
| 776 | def __del__(self): |
| 777 | """ |
| 778 | Cleanup when deleted |
| 779 | |
| 780 | """ |
| 781 | if self._process is not None: |
| 782 | try: |
| 783 | if self._process.is_alive(): |
| 784 | self._process.terminate() |
| 785 | except AssertionError: |
| 786 | # Happens on python3.4 |
| 787 | # when using PortScannerAsync twice in a row |
| 788 | pass |
| 789 | |
| 790 | self._process = None |
| 791 | return |
| 792 | |
| 793 | def scan( # NOQA: CFQ002 |
| 794 | self, |
nothing calls this directly
no outgoing calls
no test coverage detected