diff options
author | weidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0> | 2006-12-14 12:03:33 +0000 |
---|---|---|
committer | weidai <weidai@57ff6487-cd31-0410-9ec3-f628ee90f5f0> | 2006-12-14 12:03:33 +0000 |
commit | 1b1d014218165a904fe6ef99b95044f9e8d737ba (patch) | |
tree | c73be3a50a3ece4f98066984b2f0fd9f08956756 /wait.cpp | |
parent | 085c5b2d0b70a2ff3d9ccf8616a7bdf4abbc957f (diff) | |
download | cryptopp-1b1d014218165a904fe6ef99b95044f9e8d737ba.tar.gz |
port to Borland C++Builder 2006
git-svn-id: svn://svn.code.sf.net/p/cryptopp/code/trunk/c5@261 57ff6487-cd31-0410-9ec3-f628ee90f5f0
Diffstat (limited to 'wait.cpp')
-rw-r--r-- | wait.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -236,7 +236,7 @@ bool WaitObjectContainer::Wait(unsigned long milliseconds) { // too many wait objects for a single WaitForMultipleObjects call, so use multiple threads static const unsigned int WAIT_OBJECTS_PER_THREAD = MAXIMUM_WAIT_OBJECTS-1; - unsigned int nThreads = unsigned int((m_handles.size() + WAIT_OBJECTS_PER_THREAD - 1) / WAIT_OBJECTS_PER_THREAD); + unsigned int nThreads = (unsigned int)((m_handles.size() + WAIT_OBJECTS_PER_THREAD - 1) / WAIT_OBJECTS_PER_THREAD); if (nThreads > MAXIMUM_WAIT_OBJECTS) // still too many wait objects, maybe implement recursive threading later? throw Err("WaitObjectContainer: number of wait objects exceeds limit"); CreateThreads(nThreads); @@ -250,7 +250,7 @@ bool WaitObjectContainer::Wait(unsigned long milliseconds) if (i<nThreads) { thread.waitHandles = &m_handles[i*WAIT_OBJECTS_PER_THREAD]; - thread.count = STDMIN(WAIT_OBJECTS_PER_THREAD, (unsigned int)(m_handles.size() - i*WAIT_OBJECTS_PER_THREAD)); + thread.count = UnsignedMin(WAIT_OBJECTS_PER_THREAD, m_handles.size() - i*WAIT_OBJECTS_PER_THREAD); thread.error = &error; } else |