gperr - TDF error handler

SYNOPSIS

#include <gp.h>
#include <terrno.h>

void GPerr(code, set, ptr, name)
int code;
SETP set;
char *ptr;
char *name;

void (*gperr)() = GPerr;

DESCRIPTION

TDF routines call an error handler, *gperr(), when encountering an error. code is an error code from either include/gp.h or /usr/include/errno.h. set is pointer to the dataset involved in the error. ptr points to the object (dimension, variable, relation) involved in the error. name is the name of an object being created when the error occurred. set, ptr, and name may be NULL pointers.

The default error handler, GPerr, simply copies the error code into terrno.

RETURN VALUES

None.

ERRORS

The following error codes are defined in include/gp.h. Other relevant error codes are found in /usr/include/errno.h.

Errors between EGP_ERROR and EGP_ERROR +49 are dataset errors.

Invalid or corrupt dataset.

Bad datatype used to create a variable or attribute.

Cannot create two like objects with same name.

File is not a TeraScan dataset.

Bad length used trying to create attribute or link.

Bad size used trying to create dimension.

Attempting to create variable with dimension in wrong dataset.

Cannot delete dimension because it is the dimension of an existing variable.

Dimensions of variable to be linked do not match those of target dataset.

No object attribute found with given name.

No dataset dimension found with given name.

No dataset variable found with given name.

No dataset relation found with given name.

Usually means corrupt or invalid dataset.

Usually means disk full during a variable write.

Bad number of variables used trying to create a relation.

Attempting to create relation involving variables in wrong dataset.

Invalid number of variable dimensions.

Hypercube outside var bounds.

Variables do not have matching dimensions.

Cannot create variable with growing dimension that is not the leading dimension.

Cannot write variable because it is read-only.

Cannot delete variable because is used in a relation or as a dimension variable.

Invalid set pointer passed.

Invalid file pointer passed.

Invalid attribute pointer passed.

Invalid dimension pointer passed.

Invalid variable pointer passed.

Invalid relation pointer passed.

FILES

include/gp.h, include/terrno.h, /usr/include/errno.h, lib/libcdf.a

SEE ALSO

gpatt, gpdim, gpio, gplink, gpname, gprel, gpset, gptype, gpvar, datasets

NOTES

None.


Last Update: $Date: 1999/05/10 20:56:43 $