From f2f183b53d7c683f8fe420c236e305b3d1febe7f Mon Sep 17 00:00:00 2001 From: Martin Corino Date: Mon, 1 Jun 2015 11:50:53 +0200 Subject: Fix MSVC integer conversion warnings. * TAO/tao/Dynamic_TP/DTP_Task.cpp: * TAO/tao/Dynamic_TP/DTP_Thread_Pool.cpp: --- TAO/tao/Dynamic_TP/DTP_Task.cpp | 6 +++--- TAO/tao/Dynamic_TP/DTP_Thread_Pool.cpp | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/TAO/tao/Dynamic_TP/DTP_Task.cpp b/TAO/tao/Dynamic_TP/DTP_Task.cpp index 1d5a6d03f1f..30adce9c2e2 100644 --- a/TAO/tao/Dynamic_TP/DTP_Task.cpp +++ b/TAO/tao/Dynamic_TP/DTP_Task.cpp @@ -136,7 +136,7 @@ TAO_DTP_Task::open (void* /* args */) return 0; } - size_t num = this->init_pool_threads_; + int num = static_cast (this->init_pool_threads_); if (TAO_debug_level > 4) { @@ -225,7 +225,7 @@ TAO_DTP_Task::open (void* /* args */) num)); } - this->active_count_ = num; + this->active_count_ = static_cast (num); this->opened_ = true; this->accepting_requests_ = true; @@ -307,7 +307,7 @@ bool TAO_DTP_Task::need_active (void) { ACE_GUARD_RETURN (TAO_SYNCH_MUTEX, mon, this->aw_lock_, false); - return ((this->busy_threads_ == this->active_count_) && + return ((this->busy_threads_ == static_cast (this->active_count_)) && ((this->max_pool_threads_ < 1) || (this->active_count_ < this->max_pool_threads_))); } diff --git a/TAO/tao/Dynamic_TP/DTP_Thread_Pool.cpp b/TAO/tao/Dynamic_TP/DTP_Thread_Pool.cpp index d9dfb449d96..5861424f7bc 100644 --- a/TAO/tao/Dynamic_TP/DTP_Thread_Pool.cpp +++ b/TAO/tao/Dynamic_TP/DTP_Thread_Pool.cpp @@ -184,7 +184,7 @@ TAO_DTP_Thread_Pool::current_threads (void) const this->lock_, 0); - return this->threads_.thr_count (); + return static_cast (this->threads_.thr_count ()); } void @@ -336,7 +336,7 @@ TAO_DTP_Thread_Pool::create_threads_i (size_t count) -1); result = this->threads_.activate (flags, - count, + static_cast (count), force_active, default_grp_id, default_priority, -- cgit v1.2.1