aboutsummaryrefslogtreecommitdiff
path: root/paramiko/proxy.py
diff options
context:
space:
mode:
authorJeremy T. Bouse <jbouse@debian.org>2014-09-22 09:21:39 -0400
committerJeremy T. Bouse <jbouse@debian.org>2014-09-22 09:21:39 -0400
commit70f669a0a41e104bd0427e8ad9142071aae241ed (patch)
treea5c0a22c336514e1db001012a64d15477986b671 /paramiko/proxy.py
parente9306cab7448e641a54789039f5c8bfe988de320 (diff)
parentccd643cdbd7ba752727d62051058a4454451414d (diff)
downloadpython-paramiko-70f669a0a41e104bd0427e8ad9142071aae241ed.tar
python-paramiko-70f669a0a41e104bd0427e8ad9142071aae241ed.tar.gz
Merge tag 'upstream/1.15.0'
Upstream version 1.15.0
Diffstat (limited to 'paramiko/proxy.py')
-rw-r--r--paramiko/proxy.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/paramiko/proxy.py b/paramiko/proxy.py
index 8959b24..0664ac6 100644
--- a/paramiko/proxy.py
+++ b/paramiko/proxy.py
@@ -26,9 +26,10 @@ from select import select
import socket
from paramiko.ssh_exception import ProxyCommandFailure
+from paramiko.util import ClosingContextManager
-class ProxyCommand(object):
+class ProxyCommand(ClosingContextManager):
"""
Wraps a subprocess running ProxyCommand-driven programs.
@@ -36,6 +37,8 @@ class ProxyCommand(object):
`.Transport` and `.Packetizer` classes. Using this class instead of a
regular socket makes it possible to talk with a Popen'd command that will
proxy traffic between the client and a server hosted in another machine.
+
+ Instances of this class may be used as context managers.
"""
def __init__(self, command_line):
"""