- Timestamp:
- 08/08/08 14:23:27 (5 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/BAL/OWBAL/Concretizations/Types/Pthreads/BCThreadingPthreads.cpp
r424 r433 218 218 } 219 219 220 bool ThreadCondition::timedWait(Mutex& mutex, double interval)221 { 222 if ( interval< 0.0) {220 bool ThreadCondition::timedWait(Mutex& mutex, double secondsToWait) 221 { 222 if (secondsToWait < 0.0) { 223 223 wait(mutex); 224 224 return true; 225 225 } 226 227 int intervalSeconds = static_cast<int>( interval);228 int intervalMicroseconds = static_cast<int>(( interval- intervalSeconds) * 1000000.0);229 226 227 int intervalSeconds = static_cast<int>(secondsToWait); 228 int intervalMicroseconds = static_cast<int>((secondsToWait - intervalSeconds) * 1000000.0); 229 230 230 // Current time comes in sec/microsec 231 231 timeval currentTime; 232 232 gettimeofday(¤tTime, NULL); 233 233 234 234 // Target time comes in sec/nanosec 235 235 timespec targetTime;
