Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ error_handling(3P) — PHIGS 1.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

ERROR HANDLING(3P)  —  SUNPHIGS LIBRARY

NAME

ERROR HANDLING − default PHIGS error handling routine

SYNOPSIS

C Syntax

void
perrorhand ( err_num, func_num, err_file )
Pinterr_num;error number
Pintfunc_num;Number of function that detected the error
Pchar∗err_file;name of error file

FORTRAN Syntax

SUBROUTINE perhnd ( ERRNR, FCTID, ERRFIL )
INTEGERERRNRerror number
INTEGERFCTIDfunction identification
INTEGERERRFILerror file

Required PHIGS Operating States

(∗, ∗, ∗, ∗)

DESCRIPTION

Purpose

When the error handling mode is ON, ERROR HANDLING is called by PHIGS functions that detect an error in order to transfer the error information to the ERROR LOGGING subroutine and then to the error file. 

Because the error handling routine is separate from the error logging routine, the application may write its own ERROR HANDLING procedure to specify different responses to certain errors, and still use the ERROR LOGGING subroutine to record the source of the errors. 

C Input Parameters

err_num
The number of the error detected. The error numbers and corresponding error messages for each subroutine are listed with each subroutine description in this reference.

func_num
The identification of the subroutine which detected the error. This number is interpreted by the ERROR LOGGING subroutine in order to write the subroutine name on the error file. 

err_file
A pointer to a character string containing the name of the file on which to write the error information. The error file is specified in the OPEN PHIGS subroutine. 

FORTRAN Input Parameters

ERRNR
The number of the error detected. The error numbers and corresponding error messages for each subroutine are listed with each subroutine description in this reference.

FCTID
The identification of the subroutine which detected the error. This number is interpreted by the ERROR LOGGING subroutine in order to write the subroutine name on the error file. 

ERRFIL
The FORTRAN Logical Unit Number (LUN) of the file on which to write the error information. The error file is specified in the OPEN PHIGS subroutine. 

Execution

When ERROR HANDLING is called by a PHIGS subroutine that has detected an error, it receives the error number, function number, and error file from the calling subroutine, and passes these parameters on in a call to ERROR LOGGING. 

The ERROR LOGGING subroutine then writes the corresponding error message and function name onto the error file and returns to the calling function. 

ERRORS

No Error

SEE ALSO

ERROR LOGGING (3P)
SET ERROR HANDLING MODE (3P)
ESCAPE -1 (3P)

Sun Release 4.0  —  Last change: 31 July 1989

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026