How to put a timeout on receiving messages in asynchronous mode in C Solace API?

Hi @TomF / @Ragnar ,
After some research, I got a method which is :
“BOOL condTimedWait ( CONDITION_T * cond_p, MUTEX_T * mutex_p, int timeoutSec );”
It is this above method which i want to use for timeout. The existing examples in solace document uses SleepInsec(1) from “os.h” file but i have to use condTimeWait.
I got it from Os.h file.
Thanks,