




5.4. Interpreting Function Call Failures
The Dialogic ISDN software architecture uses two different levels of fault reporting to indicate the failure or success of a function call:
- High level check -- Function call failure or success is indicated by a result value: 0 = success and <0 = failure. That is, when the function fails, the function call is rejected immediately and a value <0 is returned. This means that the library or driver is unable to execute the request because it is not ready or because the request is not valid in the current state. When a value <0 is received, use the cc_CauseValue( ) function to retrieve the reason for the failure. Use the cc_ResultMsg( ) function to interpret the reason.
- Low level check (asynchronous functions only) -- In asynchronous functions, the firmware returns a termination event, in addition to the result value, to indicate the success or failure of the function. When a function fails, a result value <0 is returned along with the CCEV_TASKFAIL event. However, when an asynchronous function call fails, a result value of 0 (indicating success) can be returned along with the CCEV_TASKFAIL termination event, which indicates failure. This means that the library has accepted the request that was sent to the firmware, but at that moment, the request cannot be fulfilled due to specific circumstances or conditions. To retrieve the reason for the failure, use the cc_ResultValue( ) function. Use the cc_ResultMsg( ) function to interpret the value.
For more information on CCEV_TASKFAIL and other termination events, see Chapter 7. ISDN Events and Errors. For information on handling events, see Section 8.2.2. Handling Events.





Click here to contact Dialogic Customer Engineering
Copyright 2001, Dialogic Corporation
All rights reserved
This page generated December, 2001