diff options
author | Johnny Willemsen <jwillemsen@remedy.nl> | 2020-12-17 17:09:54 +0100 |
---|---|---|
committer | Johnny Willemsen <jwillemsen@remedy.nl> | 2020-12-17 17:09:54 +0100 |
commit | 5b17f48525edac3580a10fa9034b902e976b28f5 (patch) | |
tree | f033988a6c888c72ecac52e532c47b814b4367b0 /TAO | |
parent | 75f5f0a4747ba841326afd91dc5a4fcdf40afc37 (diff) | |
download | ATCD-5b17f48525edac3580a10fa9034b902e976b28f5.tar.gz |
Change allow_command_ to be a bool
* TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.h:
* TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.inl:
Diffstat (limited to 'TAO')
-rw-r--r-- | TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.h | 3 | ||||
-rw-r--r-- | TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.inl | 12 |
2 files changed, 7 insertions, 8 deletions
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.h b/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.h index 84f18bece00..6b2ff5f2ae4 100644 --- a/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.h +++ b/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.h @@ -63,12 +63,11 @@ public: void disallow_command (); private: - TAO_EC_Auto_Command (const TAO_EC_Auto_Command &); TAO_EC_Auto_Command & operator= (const TAO_EC_Auto_Command &); T command_; - int allow_command_; + bool allow_command_; }; diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.inl b/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.inl index 746174798a0..4b85ab2aaae 100644 --- a/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.inl +++ b/TAO/orbsvcs/orbsvcs/Event/EC_Lifetime_Utils_T.inl @@ -5,7 +5,7 @@ template <class T> ACE_INLINE TAO_EC_Auto_Command<T>::TAO_EC_Auto_Command (void) : command_ () - , allow_command_ (0) + , allow_command_ (false) { } @@ -13,7 +13,7 @@ template <class T> ACE_INLINE TAO_EC_Auto_Command<T>::TAO_EC_Auto_Command (const T & command) : command_ (command) - , allow_command_ (1) + , allow_command_ (true) { } @@ -29,7 +29,7 @@ ACE_INLINE void TAO_EC_Auto_Command<T>::set_command (const T & command) { this->command_ = command; - this->allow_command_ = 1; + this->allow_command_ = true; } template <class T> @@ -50,7 +50,7 @@ TAO_EC_Auto_Command<T>::execute (void) { if (this->allow_command_) { - this->allow_command_ = 0; + this->allow_command_ = false; try { @@ -67,14 +67,14 @@ template <class T> ACE_INLINE void TAO_EC_Auto_Command<T>::allow_command (void) { - this->allow_command_ = 1; + this->allow_command_ = true; } template <class T> ACE_INLINE void TAO_EC_Auto_Command<T>::disallow_command (void) { - this->allow_command_ = 0; + this->allow_command_ = false; } |