commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] [gnuradio] 45/50: controlport: ensure proper ctrlport


From: git
Subject: [Commit-gnuradio] [gnuradio] 45/50: controlport: ensure proper ctrlport shutdown.
Date: Wed, 15 Apr 2015 21:07:57 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

jcorgan pushed a commit to branch master
in repository gnuradio.

commit eae69f3420aea0318709b2bebe61380e8a18134f
Author: Nate Goergen <address@hidden>
Date:   Sun Mar 15 20:29:09 2015 -0500

    controlport: ensure proper ctrlport shutdown.
    
    Create instance of rpcmanager to ensure proper ctrlport shutdown and
    some minor cleanup
---
 .../include/gnuradio/thrift_application_base.h             | 14 ++++----------
 gnuradio-runtime/lib/controlport/rpcserver_selector.cc     |  4 ++++
 2 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/gnuradio-runtime/include/gnuradio/thrift_application_base.h 
b/gnuradio-runtime/include/gnuradio/thrift_application_base.h
index f649ac2..aa50c55 100644
--- a/gnuradio-runtime/include/gnuradio/thrift_application_base.h
+++ b/gnuradio-runtime/include/gnuradio/thrift_application_base.h
@@ -39,7 +39,7 @@ namespace apache { namespace thrift { namespace server { 
class TServer; } } }
 
 /*!
  * \brief  Class to be statically initialized by thrift_application_base. Used
- * to store state for thrift_application_base's static functions.
+ * to store state for thrift_application_base's singleton functions.
  */
 
 class thrift_application_base_impl
@@ -69,7 +69,7 @@ public:
  * \param TserverBase Template parameter naming the type of the server
  *   base, which is typically rpcserverbase.
  * \param TserverClass Template parameter naming the eventual type of
- *   the the fully derived application.
+ *   the fully derived application.
  * \param _app Reference to the fully derived application instance to
  *   be returned by thrift_application_base::i().
  */
@@ -208,20 +208,14 @@ void thrift_application_base<TserverBase, 
TserverClass>::start_application()
     static_cast<unsigned int>(gr::prefs::singleton()->get_long("thrift", 
"init_attempts",
                                                                
d_default_max_init_attempts));
 
-
   if(!p_impl->d_application_initilized) {
-      p_impl->d_start_thrift_thread.reset(
-      (new 
gr::thread::thread(boost::bind(&thrift_application_base::start_thrift, 
d_application))));
+    p_impl->d_start_thrift_thread.reset(
+    (new 
gr::thread::thread(boost::bind(&thrift_application_base::start_thrift, 
d_application))));
 
     bool app_started(false);
     for(unsigned int attempts(0); (!app_started && attempts < 
max_init_attempts); ++attempts) {
       
boost::this_thread::sleep(boost::posix_time::milliseconds(THRIFTAPPLICATION_ACTIVATION_TIMEOUT_MS));
-
       app_started = d_application->application_started();
-
-      if(app_started) {
-        std::cerr << "@";
-      }
     }
 
     if(!app_started) {
diff --git a/gnuradio-runtime/lib/controlport/rpcserver_selector.cc 
b/gnuradio-runtime/lib/controlport/rpcserver_selector.cc
index 57b42ca..bfb6eb9 100644
--- a/gnuradio-runtime/lib/controlport/rpcserver_selector.cc
+++ b/gnuradio-runtime/lib/controlport/rpcserver_selector.cc
@@ -26,6 +26,10 @@
 
 bool rpcmanager::make_aggregator(false);
 
+#ifdef GR_RPCSERVER_ENABLED
+rpcmanager manager_instance;;
+#endif
+
 #ifdef GR_RPCSERVER_ICE
   #error TODO ICE
 #endif



reply via email to

[Prev in Thread] Current Thread [Next in Thread]