gre_io_receive timeout

Questions and information about Crank Software's Storyboard Engine

Moderator: jamiev

gre_io_receive timeout

Postby TonyP » Wed Dec 07, 2016 3:17 pm


Is there any way to have a timeout associated with the gre_io_receive function call? I have a need to abort this blocking call after X seconds of no new communication.

Posts: 21
Joined: Thu Jul 10, 2014 11:37 am

Re: gre_io_receive timeout

Postby MikeMarchand » Tue Dec 13, 2016 11:18 am

Hi Tony,

The greio.h header file states the following: "This call blocks until an event is received or until the channel is destroyed."

Posts: 34
Joined: Wed Jan 21, 2015 3:33 pm

Re: gre_io_receive timeout

Postby jason » Tue Dec 13, 2016 11:23 am

You could have another thread in your own application send a timeout event so you can unblock yourself.

User avatar
Posts: 196
Joined: Mon Nov 02, 2009 4:53 pm

Re: gre_io_receive timeout

Postby TonyP » Tue Dec 13, 2016 11:57 am

Thanks for the info. I will end up structuring it the way Jason stated, just wanted to make sure there wasn't an alternative.
Posts: 21
Joined: Thu Jul 10, 2014 11:37 am

Return to Storyboard Engine

Who is online

Users browsing this forum: No registered users and 2 guests