Dynamic Probe Class Library

DPCL Class Reference


Chapter 2. Class AisStatus

Objects of the AisStatus class store status and severity codes returned by other DPCL functions.

Note:
The term data, as it is used in this section, refers to either a status code that is returned or a severity.

Supporting data types

AisSeverityCode

Description

AisSeverityCode is used to indicate the severity level of the associated AisStatusCode. The following are members of the enumerated type of AisSeverityCode. Refer to DPCL Programming Guide for a full description of each status code.


Table 3. AisSeverity Enumeration Types
Enumeration Type Description
ASC_attention The function completed, but the results may be incorrect. The returned AisStatusCode provides more information
ASC_error The function did not complete successfully. The returned AisStatusCode provides more information on the failure
ASC_information The function call completed normally. The returned AisStatusCode is returned for informational purposes only
ASC_severe The function did not complete successfully. The returned AisStatusCode provides more information on the failure

AisStatusCode

Description

The following are members of the enumerated type of AisStatusCode.


Table 4. AisStatus Enumeration Types
Enumeration Type Description
ASC_activate_failed Not all the given probes have been activated successfully
ASC_appl_has_no_procs The application contains no processes
ASC_arr_ptr_exp An attempt was made to apply the array operator to a probe expression that is not a pointer
ASC_auth_failed The DCE credentials supplied by the DPCL client are not authorized for execution on this node
ASC_authentication_failure The DCE credentials supplied by the DPCL client program cannot be authenticated on this node
ASC_bad_att_cfg_hostname Error parsing the hostname in attach configuration file
ASC_bad_att_cfg_ipaddr Error parsing the ip address in the attach configuration file
ASC_bad_att_cfg_numtask Error parsing number of tasks in configuration file
ASC_bad_att_cfg_pid Error parsing the pid in attach configuration file
ASC_bad_att_cfg_progname Error parsing the program name in the attach configuration file
ASC_bad_att_cfg_sid Error parsing the sid in the attach configuration file
ASC_bad_att_cfg_task Error parsing a task number in attach configuration file
ASC_bad_att_cfg_version Error parsing version in attach configuration file
ASC_bad_processd Internal error caused by an object with an invalid state
ASC_bad_pt_for_actual Attempted to install a probe expression containing an actual parameter at an InstPoint other than IPT_function_entry, IPT_function_call, or IPL_before
ASC_bad_pt_for_rtnval DPCL internal error
ASC_bad_groupid DPCL internal error
ASC_bad_rem_infile_open During a create or bcreate request, the daemon was unable to open the file specified for stdout on the remote node
ASC_bad_rem_errfile_open During a create or bcreate request, the daemon was unable to open the file specified for stderr on the remote node
ASC_bad_rem_outfile_open During a create or bcreate request, the daemon was unable to open the file specified for stdin on the remote node
ASC_bad_remote_stdin_filename The remote_stdin_filename parameter is either NULL, or the filename specified in the parameter has length 0, or is longer than UNIX allows
ASC_bad_remote_stdout_filename The remote_stdout_filename parameter is either NULL, or the filename specified in the parameter has length 0, or is longer than UNIX allows
ASC_bad_remote_stderr_filename The remote_stderr_filename parameter is either NULL, or the filename specified in the parameter has length 0, or is longer than UNIX allows
ASC_bad_userid DPCL internal error
ASC_cant_open_att_cfg_file The configuration file for setting up the PoeAppl exists but is unable to be read
ASC_child_failed The initialization process for the DPCL daemon failed
ASC_child_fork_failed DPCL internal error
ASC_communication_failure An attempt to communicate with a DPCL daemon was unsuccessful
ASC_contains_actual One-shot probe must not contain an actual parameter
ASC_contains_return_value DPCL internal error
ASC_create_msgh_failed Internal error: failed to create an internal structure
ASC_create_phase_failed Internal error: failed to create an internal structure
ASC_daem_close DPCL internal error
ASC_daem_start DPCL internal error
ASC_daemon_communication_error DPCL internal error
ASC_daemon_create_error DPCL internal error
ASC_daisd_cant_sock A UNIX connect() call failed
ASC_daisd_no_host_bname An attempt was made to contact an unknown remote host
ASC_daisd_no_info_fserv An attempt was made to run a DPCL analysis tool on a host where DPCL is either not installed or was not installed successfully
ASC_daisd_oconn_no_sock A UNIX socket() call failed
ASC_daisd_req_host DPCL internal error
ASC_deactivate_failed DPCL internal error
ASC_dead_code DPCL internal error
ASC_destroyed_process An operation, such as connect, was attempted on a process that was previously destroyed
ASC_disconnecting_process You attempted an operation, such as connect or attach, on a process that is in the process of disconnecting. The DPCL system will later place this process in the PRC_disconnected state.
ASC_duplicate_connect A connect or bconnect call has been issued and the process is already in PRC_connected state
ASC_duplicate_create A create or bcreate function has been called on an object which has already been created
ASC_duplicate_phase User attempted to install the same Phase object more than once, which is not allowed
ASC_duplicate_shm_init Internal error: an initialization function is called more than once
ASC_duplicate_signal The signal handler for the specified signal has already been added by a prior call to Ais_add_signal
ASC_empty_att_cfg_file The configuration file for setting up the PoeAppl exists and is readable but contains no information. This could occur if DPCL attempts to read the wrong file by providing a faulty pid. Another reason could be that POE was unable to write the configuration file to /tmp.
ASC_empty_object A member function of the Application class has been called where the Application object contains no member processes.
ASC_exec_failed DPCL internal error
ASC_exist_pid The pid supplied by the user is already in use by DPCL
ASC_exp_int_ptr_ops One or both operands of an operator must be an integer or pointer probe expression
ASC_exp_intg_typ The index operand of a array operator does not represent an integer-valued probe expression
ASC_exptree_con_bad_typ DPCL internal error
ASC_expand_failed DPCL internal error
ASC_failed_rhost_check The .rhosts file or the /etc/hosts.equiv file on the node that the DPCL client is attempting to connect to does not allow access to the system by this user
ASC_failure General failure on a specific DPCL call
ASC_function_op_req The ProbeExp::call operator was used with a probe expression object other than a function reference (DEN_function_type)
ASC_identd_failed An attempt to authenticate the userid by using the identd protocol failed
ASC_index_out_of_range You requested an actual parameter with an invalid index (either less than zero or greater than or equal to the number of function parameters)
ASC_initialized_process create does not want process initialized with process identifier
ASC_install_failed Install failed on the install_probe call
ASC_insufficient_memory Internal error: A memory allocation routine failed because there is not enough memory available. DPCL continues processing, but it is likely you will have subsequent problems.
ASC_int_ptr_exp The invoking object of a ProbeExp::ifelse call is not of the correct type
ASC_internal_error This message arises when unexpected values occur in certain parts of DPCL
ASC_invalid_client Internal error: failed to find an ID in an internal table
ASC_invalid_constructor DPCL internal error
ASC_invalid_expression DPCL internal error
ASC_invalid_internal_tree DPCL internal error
ASC_invalid_operand In Ais_signal call, the signal number is outside the defined domain. In Phase-related calls, the given function is not a valid function reference
ASC_invalid_operator DPCL internal error
ASC_invalid_phase A Phase object associated with a phase operation is not initialized
ASC_invalid_pid This occurs primarily in standard callbacks when an operation such as a disconnect is performed on a pid that doesn't exist. This could be that the user provided a pid that never existed, or in the case of connect, it could be an internal error.
ASC_invalid_src_code_tree DPCL internal error
ASC_invalid_value_ref DPCL internal error
ASC_invalid_version The DPCL version number sent from your DPCL client program does not match the version of the DPCL daemons
ASC_irpc_failed IRPC failed
ASC_lvalue_exp An attempt was made to store a value in a probe expression that does not represent a memory storage location
ASC_mismatch_pid Internal error: failed to match a process ID in a table
ASC_missing_aout Missing a.out file
ASC_missing_bp_func A function associated with a Phase object cannot be found
ASC_missing_phase A Phase object associated with a phase operation does not exist
ASC_missing_phase_str Internal error: an internal structure does not exist
ASC_missing_pmod DPCL internal error
ASC_missing_predef_func DPCL internal error
ASC_module_already_loaded Attempt to load the same probe module twice in the same Process
ASC_module_already_unloaded Attempt to unload a probe module that is already unloaded
ASC_module_invalid The ProbeModule name given is invalid
ASC_module_not_found The module operated upon cannot be found. This can be a case of undefined module name or module not loaded properly.
ASC_msg_init_failed Internal error: failed to initialize a message queue in an allocated shared memory segment
ASC_msg_read_failed Internal error: failed to read messages from the message queue
ASC_no_att_cfg_file Could not find attach configuration file
ASC_no_connect_from_attached A connect or bconnect call has been issued against a process object in the PRC_attached state
ASC_no_connect_from_created A connect or bconnect call has been issued against a process object in the PRC_created state
ASC_no_credentials The DPCL client did not pass any DCE credentials when trying to connect to or start a process on this node
ASC_no_create_from_attached A create or bcreate call has been issued against a process in the PRC_attached state
ASC_no_create_from_connected A create or bcreate call has been issued against a process in the PRC_connected state
ASC_no_daemon_fd During a create or bcreate request, the daemon was unable to set up a pipe for sending stdin to the target application. This create request has failed.
ASC_no_deref_vptr An attempt was made to dereference a probe expression representing a void pointer
ASC_no_detach_from_connected A detach or bdetach call has been issued against a process object in the PRC_connected state
ASC_no_detach_from_created Can issue start, attach, or destroy from created state
ASC_no_destroy_from_connected A destroy or bdestroy call has been issued against a process object which is in the PRC_connected state
ASC_no_disconnect_from_created A disconnect or bdisconnect call has been issued against a process object in the PRC_created state
ASC_no_procsinfo An attempt to connect to a process has been made. The UNIX process table does not have an entry for this particular process.
ASC_no_resume_when_running A resume or bresume call has been issued against a process object that is running
ASC_no_start_from_attached A start or bstart call has been issued against a process object in the PRC_attached state
ASC_no_start_from_connected A start or bstart call has been issued against a process object in the PRC_connected state
ASC_no_sus_res_from_connected A suspend, bsuspend, resume, or bresume call has been issued against a process which is in the PRC_connected state. The call has had no effect
ASC_no_sus_res_from_created A suspend, bsuspend, resume, or bresume call has been issued against a process which is in the PRC_created state. The call has had no effect
ASC_no_resume_when_running A resume or bresume call has been issued against a process object which is running
ASC_no_suspend_when_not_running suspend or bsuspend call has been issued against a process object which is not running
ASC_non_positive_value Phase period value is not positive
ASC_not_expansible Attempt to expand a data object that cannot be expanded further
ASC_not_full_path A create or bcreate call has been made, where one of the parameters that requires a full path to the filename was not specified as such. The path, remote_stdin_filename, remote_stdout_filename, and remote_stderr_filename parameters on the create and bcreate call require full path names.
ASC_null_pointer Attempt to call phase-related functions without a valid Process or module
ASC_operation_failed Operation failed. May be an internal error or the result of an invalid index.
ASC_phase_exit_done A Phase object, associated with the set_phase_exit() call, has completed its execution. The set_phase_exit() call will have no effect on the Phase object.
ASC_phase_malloc_data_failed Internal error: DPCL daemon failed to allocate a probe data for a Phase object
ASC_phase_null_data_func An attempt to allocate a block of probe data for a Phase object failed because the Phase object does not have a data function associated with it.
ASC_process_already_attached An attach or battach call has been issued against a process object which is already in PRC_attached state. Note that it may be this DPCL analysis tool or another which is in the PRC_attached state. Only one DPCL analysis tool may be attached to a particular process at a time
ASC_process_not_connected The DPCL client attempted to perform an operation on a process that is either not connected to, or has since been disconnected from. This error can occur if the client attempts to install probes on a process that is not connected.
ASC_process_not_created A send_stdin call has been made against a process object which was not initially created with a create or bcreate call
ASC_proto_few_par The function prototype object of a ProbeType::get_actual call does not have enough parameters defined for the index requested
ASC_proto_ret_no_void DPCL internal error
ASC_PT_func_proto The invoking ProbeType object of a ProbeType::get_actual call does not represent a function prototype
ASC_ptr_exp The invoking object of a ProbeExp::operator* call does not represent a pointer
ASC_remote_stdin_file A send_stdin call has been made against a process object which was created by a DPCL create or bcreate call. When the create or bcreate call was made, the remote_stdin_file parameter was specified. This overrides any further ability to use the send_stdin call against this process
ASC_remove_failed Failed to remove one or more probes
ASC_remove_msgh_failed Internal error: an internal structure does not exist
ASC_root_not_allowed The root userid is not allowed to start or connect to a process with DPCL using the COMPAT security model
ASC_duplicate_shm_init Duplicate shm init
ASC_security_failure DPCL internal error
ASC_security_init_failed DPCL internal error
ASC_shm_attach_failed The target application failed to attach to the shared memory segment allocated by the DPCL daemon
ASC_shm_block_alloc_failed Internal error: failed to allocate a block in a shared memory segment
ASC_shm_init_failed Internal error: DPCL daemon failed to initialize a shared memory segment
ASC_shm_object_alloc_failed Internal error: failed to allocate an object in a shared memory segment
ASC_shm_verify_failed Internal error: verification on a shared memory segment failed
ASC_shmat_failed A call to shmat failed
ASC_shmctl_failed A call to shmctl failed
ASC_shmdt_failed A call to shmdt failed
ASC_shmget_failed A call to shmget failed
ASC_success The operation has completed successfully
ASC_terminated_pid An attempt to issue a Process-related call on a terminated process
ASC_type_mismatch The operands of a probe-expression operator have incompatible data types
ASC_uninitialized_daemon DPCL internal error
ASC_uninitialized_process Internal error: an internal structure does not exist
ASC_unknown_status DPCL expected an AisStatus object to be of a specific value, but it had some other value instead
ASC_valid_pe_req_assign An attempt was made to store a value in a probe expression that does not represent a valid probe expression
ASC_valid_pe_req_else A valid probe expression is required for the else clause of a ProbeExp::ifelse operator
ASC_valid_pe_req_if A valid probe expression is required for the then clause of a ProbeExp::ifelse operator
ASC_valid_pe_req_seq The ProbeExp::call operator was used with a probe expression object other than a function reference (DEN_function_type)

Description

The AisStatusCode enumeration type is used to indicate the completion status of a call to a DPCL function. AisStatusCode is used in conjunction with AisSeverityCode to indicate the success or failure of that call.

Constructors

Synopsis

#include <AisStatus.h>
AisStatus(
	AisStatusCode status = ASC_success,
	AisSeverity severity = ASC_information)
AisStatus(const AisStatus &copy);

Parameters

status
Valid values are 0 <= status <= ASC_LAST_STATUS_VALUE

severity
Valid values are 0 <= severity <= ASC_LAST_SEVERITY_VALUE

Description

Class constructor. This constructor initializes an AisStatus object to reflect the specific status and severity codes.

Exceptions

ASC_failure
AisStatusCode or AisSeverityCode is an invalid value

add_data

Synopsis

#include <AisStatus.h>
void add_data(const char *data)

Parameters

data
a pointer to a character string representation of the data

Description

Adds one data value to the list of data associated with this Ais_status object.

See Also

data_count, data_value, data_value_length

data_count

Synopsis

#include <AisStatus.h>
int data_count(void) const;

Description

Returns the number of data values associated with this condition.

Return Values

Returns the count of data values reflected in the object.

data_value

Synopsis

#include <AisStatus.h>
char *data_value(
    int i,
    char *buffer,
    unsigned int len) const;

Parameters

i
index value

buffer
caller-allocated buffer that holds the data value

len
maximum number of bytes the function places in buffer. The len parameter should include enough space for a terminating NULL byte.

Description

A NULL-terminated string representation of the ith data value will be placed at the location specified by buffer. The value may be truncated if the len parameter is smaller than the length of the data value.

Return Values

If the index is valid, in other words, 0 <= i < data_count(), then the return value is a pointer to buffer containing, at most, len bytes of the data value.

It returns NULL if the index is not valid.

See Also

data_count, data_value_length

data_value_length

Synopsis

#include <AisStatus.h>
unsigned int data_value_length(int i) const;

Parameters

i
index value

Description

Returns the length, including the terminating NULL byte, of the string representation of the ith data value.

Return Values

If the index is valid, in other words, 0 <= i < data_count(), then the return value is the length of the ith data value.

It returns 0 if the index is not valid.

See Also

data_count, data_value

operator =

Synopsis

#include <AisStatus.h>
AisStatus &operator = (const AisStatus &copy)

Parameters

copy
object to be copied in the assignment

Description

Assigns the value of the right-hand operand to the invoking object. The left-hand operand is the invoking object.

For example,

Ais_Status rhs, lhs; ... lhs = rhs;

assigns the value of rhs to lhs. Both Ais_Status objects contain the same value.

Return Values

Returns a reference to the left-hand side of the assignment.

operator AisStatusCode

Synopsis

#include <AisStatus.h>
operator AisStatusCode(void) const;

Description

Cast function. Returns the AisStatusCode contained in the object.

The following is an example of how this function could be coded:

AisStatus full_status;
AisStatusCode status_code;


·
·
·

status_code=(AisStatusCode) full_status;


·
·
·

Return Values

Returns the status code in the object, of data type AisStatusCode.

operator int

Synopsis

#include <AisStatus.h>
operator int(void) const;

Description

Cast function. Returns the integer equivalent of the status code reflected in the object. A status value of 0 reflects success.

Return Values

Returns the integer equivalent of the status value AisStatusCode, and 0 reflects success.

severity

Synopsis

#include <AisStatus.h>
AisSeverityCode severity(void) const;

Description

Returns the severity contained in the object.

Return Values

Returns the severity code in the object, of data type AisSeverityCode.

status

Synopsis

#include <AisStatus.h>
AisStatusCode status(void) const;

Description

Returns the status code contained in the object.

Return Values

Returns the status code in the object, of data type AisStatusCode.

status_name

Synopsis

#include <AisStatus.h>
const char *status_name(void) const;

Description

Returns the name of the status code contained in the object. The name is in American English, and the string is stored in a constant array within the function. This function is intended only for limited diagnostic use during tool development.

Return Values

Returns the name of the status code in the object, of data type char *.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]