Merge branch 'development' into LTS_development
This commit is contained in:
commit
6bca77d758
3 changed files with 8 additions and 0 deletions
|
|
@ -223,6 +223,7 @@ namespace IPC {
|
|||
|
||||
///\brief Tries to wait for the semaphore, returns true if successful, false otherwise
|
||||
bool semaphore::tryWait() {
|
||||
if (!(*this)){return false;}
|
||||
int result;
|
||||
#if defined(__CYGWIN__) || defined(_WIN32)
|
||||
result = WaitForSingleObject(mySem, 0);//wait at most 1ms
|
||||
|
|
@ -238,6 +239,7 @@ namespace IPC {
|
|||
|
||||
///\brief Tries to wait for the semaphore for a single second, returns true if successful, false otherwise
|
||||
bool semaphore::tryWaitOneSecond() {
|
||||
if (!(*this)){return false;}
|
||||
int result;
|
||||
#if defined(__CYGWIN__) || defined(_WIN32)
|
||||
result = WaitForSingleObject(mySem, 1000);//wait at most 1s
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue