diff options
author | Lars-Dominik Braun <lars@6xq.net> | 2018-03-25 14:03:04 +0200 |
---|---|---|
committer | Lars-Dominik Braun <lars@6xq.net> | 2018-03-25 14:43:30 +0200 |
commit | 1efbd6de5e788bbb424602edd6321a0cba79bb04 (patch) | |
tree | 4762bb5b78675d3cb5ad427064cfa144e88d3370 /crocoite | |
parent | a21d7332e33a3e47a363004196451721d449e70b (diff) | |
download | crocoite-1efbd6de5e788bbb424602edd6321a0cba79bb04.tar.gz crocoite-1efbd6de5e788bbb424602edd6321a0cba79bb04.tar.bz2 crocoite-1efbd6de5e788bbb424602edd6321a0cba79bb04.zip |
ChromeService: Close listening socket
We passed it to the child and don’t need it any more.
Diffstat (limited to 'crocoite')
-rw-r--r-- | crocoite/browser.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/crocoite/browser.py b/crocoite/browser.py index b4ade56..4fe37d8 100644 --- a/crocoite/browser.py +++ b/crocoite/browser.py @@ -325,6 +325,7 @@ def ChromeService (binary='google-chrome-stable', host='localhost', port=9222, w p = subprocess.Popen (args, pass_fds=[s.fileno()], start_new_session=True, stdin=subprocess.DEVNULL, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) + s.close () # must be wrapped in try-finally, otherwise code in __exit__/finally is not # executed |