THRIFT-567. cpp: Can't immediately stop a TSimpleServer thread that is idle
authorBryan Duxbury <bryanduxbury@apache.org>
Thu, 2 Sep 2010 15:16:56 +0000 (15:16 +0000)
committerBryan Duxbury <bryanduxbury@apache.org>
Thu, 2 Sep 2010 15:16:56 +0000 (15:16 +0000)
This interrupts the server in addition to setting the stop flag.

Patch: Rush Manbert

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@991974 13f79535-47bb-0310-9956-ffa450edef68

lib/cpp/src/server/TSimpleServer.h

index c4fc91c..29e120e 100644 (file)
@@ -58,6 +58,7 @@ class TSimpleServer : public TServer {
 
   void stop() {
     stop_ = true;
+    serverTransport_->interrupt();
   }
 
  protected: