commit | 7c1f6f8e338e9491a2bbe777bfd30d7f1748a727 | [log] [tgz] |
---|---|---|
author | David Reiss <dreiss@apache.org> | Tue Mar 24 20:10:24 2009 +0000 |
committer | David Reiss <dreiss@apache.org> | Tue Mar 24 20:10:24 2009 +0000 |
tree | 061a88c167afda25f034b20e5cfc51d49656bf92 | |
parent | cecbed81c806e40ca0342d7b8e265d2bf55a2f04 [diff] [blame] |
THRIFT-155. python: Reopen THttpClient on a flush git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@757996 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/py/src/transport/THttpClient.py b/lib/py/src/transport/THttpClient.py index 48f75a4..f577192 100644 --- a/lib/py/src/transport/THttpClient.py +++ b/lib/py/src/transport/THttpClient.py
@@ -37,6 +37,10 @@ self.__wbuf.write(buf) def flush(self): + if self.isOpen(): + self.close() + self.open(); + # Pull data out of buffer data = self.__wbuf.getvalue() self.__wbuf = StringIO()