diff options
author | Steve Huston <shuston@riverace.com> | 2002-07-22 21:03:37 +0000 |
---|---|---|
committer | Steve Huston <shuston@riverace.com> | 2002-07-22 21:03:37 +0000 |
commit | 5524925d82f66d235692199f4cb90f5db08d2c3d (patch) | |
tree | 818f8d23f8764dd530912ea45e486a912ff8ae24 /ace | |
parent | b311cda8e44cd37088d74167afced02d493d8b65 (diff) | |
download | ATCD-5524925d82f66d235692199f4cb90f5db08d2c3d.tar.gz |
ChangeLogTag:Mon Jul 22 16:39:21 2002 Steve Huston <shuston@riverace.com>
Diffstat (limited to 'ace')
-rw-r--r-- | ace/Acceptor.cpp | 6 | ||||
-rw-r--r-- | ace/Connector.cpp | 2 | ||||
-rw-r--r-- | ace/Message_Queue.cpp | 11 | ||||
-rw-r--r-- | ace/Message_Queue.h | 8 | ||||
-rw-r--r-- | ace/Message_Queue.i | 4 | ||||
-rw-r--r-- | ace/Message_Queue_T.cpp | 2 | ||||
-rw-r--r-- | ace/Message_Queue_T.h | 40 | ||||
-rw-r--r-- | ace/Message_Queue_T.i | 4 | ||||
-rw-r--r-- | ace/SOCK_IO.h | 4 | ||||
-rw-r--r-- | ace/SOCK_IO.i | 8 | ||||
-rw-r--r-- | ace/SOCK_Stream.h | 4 | ||||
-rw-r--r-- | ace/SOCK_Stream.i | 4 |
12 files changed, 49 insertions, 48 deletions
diff --git a/ace/Acceptor.cpp b/ace/Acceptor.cpp index 004d65628a0..4f9b270f97d 100644 --- a/ace/Acceptor.cpp +++ b/ace/Acceptor.cpp @@ -179,7 +179,7 @@ ACE_Acceptor<SVC_HANDLER, ACE_PEER_ACCEPTOR_2>::info (ACE_TCHAR **strp, return -1; else ACE_OS::strsncpy (*strp, buf, length); - return ACE_OS::strlen (buf); + return ACE_static_cast (int, ACE_OS::strlen (buf)); } template <class SVC_HANDLER, ACE_PEER_ACCEPTOR_1> int @@ -809,7 +809,7 @@ ACE_Strategy_Acceptor<SVC_HANDLER, ACE_PEER_ACCEPTOR_2>::info (ACE_TCHAR **strp, return -1; else ACE_OS::strsncpy (*strp, buf, length); - return ACE_OS::strlen (buf); + return ACE_static_cast (int, ACE_OS::strlen (buf)); } template <class SVC_HANDLER, ACE_PEER_ACCEPTOR_1> int @@ -1161,7 +1161,7 @@ ACE_Oneshot_Acceptor<SVC_HANDLER, ACE_PEER_ACCEPTOR_2>::info (ACE_TCHAR **strp, return -1; else ACE_OS::strsncpy (*strp, buf, length); - return ACE_OS::strlen (buf); + return ACE_static_cast (int, ACE_OS::strlen (buf)); } template <class SVC_HANDLER, ACE_PEER_ACCEPTOR_1> int diff --git a/ace/Connector.cpp b/ace/Connector.cpp index c63ca5e53a4..7da336b8ed8 100644 --- a/ace/Connector.cpp +++ b/ace/Connector.cpp @@ -722,7 +722,7 @@ ACE_Connector<SVH, PR_CO_2>::info (ACE_TCHAR **strp, size_t length) const return -1; else ACE_OS::strsncpy (*strp, buf, length); - return ACE_OS::strlen (buf); + return ACE_static_cast (int, ACE_OS::strlen (buf)); } template <class SVH, PR_CO_1> diff --git a/ace/Message_Queue.cpp b/ace/Message_Queue.cpp index 3453c8b29c1..a05fdc4d5c3 100644 --- a/ace/Message_Queue.cpp +++ b/ace/Message_Queue.cpp @@ -420,9 +420,9 @@ ACE_Message_Queue_NT::deactivate (void) // Get the number of shutdown messages necessary to wake up all // waiting threads. - - for (size_t cntr = this->cur_thrs_ - this->cur_count_; - cntr > 0; cntr++) + size_t cntr = + this->cur_thrs_ - ACE_static_cast (size_t, this->cur_count_); + while (cntr-- > 0) ::PostQueuedCompletionStatus (this->completion_port_, 0, this->state_, @@ -455,8 +455,9 @@ ACE_Message_Queue_NT::pulse (void) // Get the number of shutdown messages necessary to wake up all // waiting threads. - for (size_t cntr = this->cur_thrs_ - this->cur_count_; - cntr > 0; cntr++) + size_t cntr = + this->cur_thrs_ - ACE_static_cast (size_t, this->cur_count_); + while (cntr-- > 0) ::PostQueuedCompletionStatus (this->completion_port_, 0, this->state_, diff --git a/ace/Message_Queue.h b/ace/Message_Queue.h index 5768d9879cd..8a075339a1c 100644 --- a/ace/Message_Queue.h +++ b/ace/Message_Queue.h @@ -144,7 +144,7 @@ public: virtual size_t message_length (void) = 0; /// Number of total messages on the queue. - virtual size_t message_count (void) = 0; + virtual int message_count (void) = 0; /// New value of the number of total bytes on the queue, i.e., /// sum of the message block sizes. @@ -289,7 +289,7 @@ public: /** * Number of total messages on the queue. */ - virtual size_t message_count (void); + virtual int message_count (void); // = Manual changes to these stats (used when queued message blocks // change size or lengths). @@ -493,7 +493,7 @@ public: /** * Number of total messages on the queue. */ - virtual size_t message_count (void); + virtual int message_count (void); // = Manual changes to these stats (used when queued message blocks // change size or lengths). @@ -577,7 +577,7 @@ private: size_t cur_length_; /// Current number of messages in the queue. - size_t cur_count_; + int cur_count_; /** * Synchronizer. This should really be an ACE_Recursive_Thread_Mutex diff --git a/ace/Message_Queue.i b/ace/Message_Queue.i index f353a1a1cbe..17f5c02ee13 100644 --- a/ace/Message_Queue.i +++ b/ace/Message_Queue.i @@ -87,7 +87,7 @@ ACE_Message_Queue_Vx::message_length (void) ACE_NOTSUP_RETURN ((size_t) -1); } -ACE_INLINE size_t +ACE_INLINE int ACE_Message_Queue_Vx::message_count (void) { ACE_TRACE ("ACE_Message_Queue_Vx::message_count"); @@ -161,7 +161,7 @@ ACE_Message_Queue_NT::message_length (void) return this->cur_length_; } -ACE_INLINE size_t +ACE_INLINE int ACE_Message_Queue_NT::message_count (void) { ACE_TRACE ("ACE_Message_Queue_NT::message_count"); diff --git a/ace/Message_Queue_T.cpp b/ace/Message_Queue_T.cpp index e480a2c36a2..07e461a71da 100644 --- a/ace/Message_Queue_T.cpp +++ b/ace/Message_Queue_T.cpp @@ -510,7 +510,7 @@ ACE_Message_Queue<ACE_SYNCH_USE>::~ACE_Message_Queue (void) template <ACE_SYNCH_DECL> int ACE_Message_Queue<ACE_SYNCH_USE>::flush_i (void) { - size_t number_flushed = 0; + int number_flushed = 0; // Remove all the <ACE_Message_Block>s in the <ACE_Message_Queue> // and <release> their memory. diff --git a/ace/Message_Queue_T.h b/ace/Message_Queue_T.h index 63c9831563a..f0e0d34a0f7 100644 --- a/ace/Message_Queue_T.h +++ b/ace/Message_Queue_T.h @@ -132,12 +132,12 @@ public: * Retrieve a poiner to the first ACE_Message_Block in the queue * without removing it. * - * @arg first_item Reference to an ACE_Message_Block * that will - * point to the first block on the queue. The block - * remains on the queue until this or another thread - * dequeues it. - * @arg timeout The absolute time the caller will wait until - * for a block to be queued. + * @param first_item Reference to an ACE_Message_Block * that will + * point to the first block on the queue. The block + * remains on the queue until this or another thread + * dequeues it. + * @param timeout The absolute time the caller will wait until + * for a block to be queued. * * @retval The number of ACE_Message_Blocks on the queue. * @return -1 on failure. errno holds the reason. If EWOULDBLOCK, @@ -153,11 +153,11 @@ public: * order is maintained when messages of the same priority are * inserted consecutively. * - * @arg new_item Pointer to an ACE_Message_Block that will be - * added to the queue. The block's @c msg_priority() - * method will be called to obtain the queueing priority. - * @arg timeout The absolute time the caller will wait until - * for the block to be queued. + * @param new_item Pointer to an ACE_Message_Block that will be + * added to the queue. The block's @c msg_priority() + * method will be called to obtain the queueing priority. + * @param timeout The absolute time the caller will wait until + * for the block to be queued. * * @retval The number of ACE_Message_Blocks on the queue after adding * the specified block. @@ -287,7 +287,7 @@ public: /** * Number of total messages on the queue. */ - virtual size_t message_count (void); + virtual int message_count (void); // = Manual changes to these stats (used when queued message blocks // change size or lengths). @@ -444,12 +444,12 @@ protected: * so they can wakeup and continue other processing. * No messages are removed from the queue. * - * @arg pulse If 0, the queue's state is changed to DEACTIVATED - * and any other operations called until the queue is - * reactivated will immediately return -1 with - * errno == ESHUTDOWN. - * If not zero, only the waiting threads are notified and - * the queue's state changes to PULSED. + * @param pulse If 0, the queue's state is changed to DEACTIVATED + * and any other operations called until the queue is + * reactivated will immediately return -1 with + * errno == ESHUTDOWN. + * If not zero, only the waiting threads are notified and + * the queue's state changes to PULSED. * * @retval The state of the queue before the call. */ @@ -493,7 +493,7 @@ protected: size_t cur_length_; /// Current number of messages in the queue. - size_t cur_count_; + int cur_count_; /// The notification strategy used when a new message is enqueued. ACE_Notification_Strategy *notification_strategy_; @@ -1107,7 +1107,7 @@ public: /** * Number of total messages on the queue. */ - virtual size_t message_count (void); + virtual int message_count (void); // = Manual changes to these stats (used when queued message blocks // change size or lengths). diff --git a/ace/Message_Queue_T.i b/ace/Message_Queue_T.i index d04fd9041a3..3cd1e3cd719 100644 --- a/ace/Message_Queue_T.i +++ b/ace/Message_Queue_T.i @@ -119,7 +119,7 @@ ACE_Message_Queue<ACE_SYNCH_USE>::message_length (void) return this->cur_length_; } -template <ACE_SYNCH_DECL> ACE_INLINE size_t +template <ACE_SYNCH_DECL> ACE_INLINE int ACE_Message_Queue<ACE_SYNCH_USE>::message_count (void) { ACE_TRACE ("ACE_Message_Queue<ACE_SYNCH_USE>::message_count"); @@ -277,7 +277,7 @@ ACE_Message_Queue_Ex<ACE_MESSAGE_TYPE, ACE_SYNCH_USE>::message_length (void) return this->queue_.message_length (); } -template <class ACE_MESSAGE_TYPE, ACE_SYNCH_DECL> ACE_INLINE size_t +template <class ACE_MESSAGE_TYPE, ACE_SYNCH_DECL> ACE_INLINE int ACE_Message_Queue_Ex<ACE_MESSAGE_TYPE, ACE_SYNCH_USE>::message_count (void) { ACE_TRACE ("ACE_Message_Queue_Ex<ACE_MESSAGE_TYPE, ACE_SYNCH_USE>::message_count"); diff --git a/ace/SOCK_IO.h b/ace/SOCK_IO.h index 77ba78471fb..67b4be8a5d8 100644 --- a/ace/SOCK_IO.h +++ b/ace/SOCK_IO.h @@ -69,7 +69,7 @@ public: /// Recv an <iovec> of size <n> from the connected socket. ssize_t recvv (iovec iov[], - size_t n, + int n, const ACE_Time_Value *timeout = 0) const; /// Same as above. Deprecated. @@ -114,7 +114,7 @@ public: /// Send an <iovec> of size <n> to the connected socket. ssize_t sendv (const iovec iov[], - size_t n, + int n, const ACE_Time_Value *timeout = 0) const; /// Same as above. Deprecated. diff --git a/ace/SOCK_IO.i b/ace/SOCK_IO.i index d46ca3c188f..f8f91016330 100644 --- a/ace/SOCK_IO.i +++ b/ace/SOCK_IO.i @@ -45,7 +45,7 @@ ACE_SOCK_IO::recv (void *buf, ASYS_INLINE ssize_t ACE_SOCK_IO::recvv (iovec iov[], - size_t n, + int n, const ACE_Time_Value *timeout) const { ACE_TRACE ("ACE_SOCK_IO::recvv"); @@ -62,7 +62,7 @@ ACE_SOCK_IO::recv (iovec iov[], { ACE_TRACE ("ACE_SOCK_IO::recv"); return this->recvv (iov, - n, + ACE_static_cast (int, n), timeout); } @@ -115,7 +115,7 @@ ACE_SOCK_IO::send (const void *buf, ASYS_INLINE ssize_t ACE_SOCK_IO::sendv (const iovec iov[], - size_t n, + int n, const ACE_Time_Value *timeout) const { ACE_TRACE ("ACE_SOCK_IO::sendv"); @@ -132,7 +132,7 @@ ACE_SOCK_IO::send (const iovec iov[], { ACE_TRACE ("ACE_SOCK_IO::send"); return this->sendv (iov, - n, + ACE_static_cast (int, n), timeout); } diff --git a/ace/SOCK_Stream.h b/ace/SOCK_Stream.h index f478702aaaa..4e671edae15 100644 --- a/ace/SOCK_Stream.h +++ b/ace/SOCK_Stream.h @@ -96,7 +96,7 @@ public: /// Receive an <iovec> of size <iovcnt> from the connected socket. ssize_t recvv_n (iovec iov[], - size_t iovcnt, + int iovcnt, const ACE_Time_Value *timeout = 0, size_t *bytes_transferred = 0) const; @@ -122,7 +122,7 @@ public: /// Send an <iovec> of size <iovcnt> to the connected socket. ssize_t sendv_n (const iovec iov[], - size_t iovcnt, + int iovcnt, const ACE_Time_Value *timeout = 0, size_t *bytes_transferred = 0) const; diff --git a/ace/SOCK_Stream.i b/ace/SOCK_Stream.i index 0684e069832..f13d0ca24ff 100644 --- a/ace/SOCK_Stream.i +++ b/ace/SOCK_Stream.i @@ -76,7 +76,7 @@ ACE_SOCK_Stream::recv_n (void *buf, ASYS_INLINE ssize_t ACE_SOCK_Stream::recvv_n (iovec iov[], - size_t n, + int n, const ACE_Time_Value *timeout, size_t *bytes_transferred) const { @@ -120,7 +120,7 @@ ACE_SOCK_Stream::send_n (const void *buf, ASYS_INLINE ssize_t ACE_SOCK_Stream::sendv_n (const iovec iov[], - size_t n, + int n, const ACE_Time_Value *timeout, size_t *bytes_transferred) const { |