Repository: thrift
Updated Branches:
  refs/heads/master d5536d1ea -> c6ded922c


THRIFT-4154: properly close socket whether it is persistent or not on close()
Client: php

This closes #1011
This closes #1233


Project: http://git-wip-us.apache.org/repos/asf/thrift/repo
Commit: http://git-wip-us.apache.org/repos/asf/thrift/commit/c6ded922
Tree: http://git-wip-us.apache.org/repos/asf/thrift/tree/c6ded922
Diff: http://git-wip-us.apache.org/repos/asf/thrift/diff/c6ded922

Branch: refs/heads/master
Commit: c6ded922c586cad7f66b57a123fec520e5c36a5e
Parents: d5536d1
Author: James E. King, III <[email protected]>
Authored: Sat Apr 1 23:26:54 2017 -0400
Committer: James E. King, III <[email protected]>
Committed: Sat Apr 1 23:26:54 2017 -0400

----------------------------------------------------------------------
 lib/php/lib/Thrift/Transport/TSocket.php | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/thrift/blob/c6ded922/lib/php/lib/Thrift/Transport/TSocket.php
----------------------------------------------------------------------
diff --git a/lib/php/lib/Thrift/Transport/TSocket.php 
b/lib/php/lib/Thrift/Transport/TSocket.php
index 10d5115..1495047 100644
--- a/lib/php/lib/Thrift/Transport/TSocket.php
+++ b/lib/php/lib/Thrift/Transport/TSocket.php
@@ -248,10 +248,8 @@ class TSocket extends TTransport
    */
   public function close()
   {
-    if (!$this->persist_) {
-      @fclose($this->handle_);
-      $this->handle_ = null;
-    }
+    @fclose($this->handle_);
+    $this->handle_ = null;
   }
 
   /**

Reply via email to