HP-UX C SIP Stack Programmer's Guide (Novembery 2007)

Creating an Application 35
Event Processing
The SIP Stack configuration parameters will adjust to the new numbers you set.
For more information about the SIP Stack configuration, see the Configuration
chapter.
EVENT
P
ROCESSING
After initializing the SIP Stack, you will need to instruct the SIP Stack to
process events as they occur. You do this by calling the function,
RvSipStackProcessEvents() from the same thread that constructed the SIP
Stack.
You can alternatively use the functions, RvSipStackSelect() or
RvSipStackSelectUntil(). These functions perform one call to the select()
operating system function. Both of the above functions should be called in an
application loop.
Sample Code
The following code demonstrates how to instruct the SIP Stack to process
incoming events.
/*==========================================================================*/
int main()
{
RvStatus rv;
/*Initialize the SIP stack*/
rv = AppInitSipStack();
if(rv != RV_OK)
{
printf("failed to initialize the SIP Stack\n");
return -1;
}
. . .
/* Commands the Stack to process the events queue.*/
RvSipStackProcessEvents();
return 0;
}
/*==========================================================================*/