Fix file descriptor leak in service on quit().

This commit is contained in:
Zachary Kulis 2024-04-02 22:51:21 -04:00
parent 0aa5fbe252
commit 94672f4cb5
1 changed files with 2 additions and 0 deletions

View File

@ -763,7 +763,9 @@ class Chrome(selenium.webdriver.chrome.webdriver.WebDriver):
def quit(self): def quit(self):
try: try:
self.service.stop()
self.service.process.kill() self.service.process.kill()
self.command_executor.close()
logger.debug("webdriver process ended") logger.debug("webdriver process ended")
except (AttributeError, RuntimeError, OSError): except (AttributeError, RuntimeError, OSError):
pass pass