PREV TOC HOME INDEX NEXT


gc_ResultMsg( )


Termination Events | Cautions | Errors | Example | See Also

Name: int gc_ResultMsg(cclibid, result_code, msg)
Inputs:

int cclibid

  • call control library ID
 

long result_code

  • used to get associated message
 

char **msg

  • pointer to address of returned message string
Returns:

0 if successful

<0 if failure

Includes:

gclib.h

gcerr.h

Category:

system controls and tools (deprecated)

Mode:

synchronous

Platform and Technology:

Springware: T-1/E-1, ISDN, Analog

DM3: T-1/E-1, ISDN, Analog

SS7

IP (embedded stack)

Description

Note: The gc_ResultMsg( ) function is deprecated in this software release. The suggested alternative is gc_ResultInfo( ) to retrieve event information or gc_ErrorInfo( ) to retrieve error information.

The gc_ResultMsg( ) function retrieves an ASCII string describing a result code. The result_code parameter may represent an error code returned by the gc_ErrorValue( ) function or a result value returned by a gc_ResultValue( ) function.

Parameter

Description

cclibid call control library identification from which the result_code was generated. If the result_code value is a Global Call error code or result value, then set cclibid to LIBID_GC.
result_code result value of the event or error code from the library, cclibid
msg points to address where the description of the result_code message will be stored

Termination Events

None

Cautions

Do not overwrite the *msg pointer since it points to private internal Global Call data space.

Errors

If this function returns <0 to indicate failure, no additional information is available to indicate why the function failed. Generally, a failure of this function is caused by passing an invalid cclibid or msg parameter.

Example

#include <stdio.h>
#include <srllib.h>
#include <gclib.h>
#include <gcerr.h> 
/* cclibid = LIBID_GC to print GC Lib's result value */
void print_result_msg(int cclibid, long result_code)
{  
    char           *msg;             /* points to the error message string */
    char           *lib_name;        /* library name for cclibid */ 
    if (gc_ResultMsg(cclibid, result_code, &msg) == GC_SUCCESS) {
        gc_CCLibIDToName(cclibid, &lib_name);
        printf("%s library had error 0x%lx - %s\n", lib_name, result_code, msg);
    } else {
        printf("gc_ResultMsg failed\n");
    }
} 

See Also


PREV TOC HOME INDEX NEXT

Click here to contact Telecom Support Resources

Copyright 2003, Intel Corporation
All rights reserved
This page generated February, 2003