From: Bryan Duxbury Date: Fri, 4 Mar 2011 01:35:17 +0000 (+0000) Subject: THRIFT-867. php: PHP accelerator module's output transport is incompatible with TFram... X-Git-Tag: 0.7.0~161 X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=e7b1864d46da8939935ed17530e2510e37a1f2ad;p=common%2Fthrift.git THRIFT-867. php: PHP accelerator module's output transport is incompatible with TFramedTransport This patch prevents TFramedTransport from flushing empty frames. git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1076918 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/lib/php/src/transport/TFramedTransport.php b/lib/php/src/transport/TFramedTransport.php index dc57392f..b1c0bb5c 100644 --- a/lib/php/src/transport/TFramedTransport.php +++ b/lib/php/src/transport/TFramedTransport.php @@ -161,7 +161,7 @@ class TFramedTransport extends TTransport { * followed by the actual data. */ public function flush() { - if (!$this->write_) { + if (!$this->write_ || strlen($this->wBuf_) == 0) { return $this->transport_->flush(); }