From 378701d63292f8ae883b159695254a6a663ba307 Mon Sep 17 00:00:00 2001 From: Quincey Koziol Date: Sat, 12 Jul 2003 12:02:33 -0500 Subject: [svn-r7214] Purpose: Code cleanup/bug fix Description: Clean up code a bit and make hid_t's for error class to use the same scheme as predefined datatype hid_t's. Platforms tested: FreeBSD 4.8 (sleipnir) w/C++ h5committest --- src/H5E.c | 64 ++++++++++----- src/H5Eprivate.h | 233 +++++++++++++++++++++++++++++-------------------------- src/H5Epublic.h | 45 +++++------ 3 files changed, 187 insertions(+), 155 deletions(-) diff --git a/src/H5E.c b/src/H5E.c index cd10b49..15657c0 100644 --- a/src/H5E.c +++ b/src/H5E.c @@ -74,6 +74,7 @@ static const H5E_major_mesg_t H5E_major_mesg_g[] = { {H5E_FPHDF5, "Flexible Parallel HDF5"}, {H5E_TST, "Ternary Search Trees"}, {H5E_RS, "Reference Counted Strings"}, + {H5E_ERROR, "Error API"}, }; static const H5E_minor_mesg_t H5E_minor_mesg_g[] = { @@ -195,7 +196,17 @@ static const H5E_minor_mesg_t H5E_minor_mesg_g[] = { /* Interface initialization? */ static int interface_initialize_g = 0; #define INTERFACE_INIT H5E_init_interface -static herr_t H5E_init_interface (void); + +#ifndef NEW_ERR +/* + * Predefined errors. These are initialized at runtime in H5E_init_interface() + * in this source file. + * + * If more of these are added, the new ones must be added to the list of + * types to reset in H5E_term_interface(). + */ +hid_t H5E_ERR_CLS_g = FAIL; +#endif /* NEW_ERR */ #ifdef H5_HAVE_THREADSAFE /* @@ -236,6 +247,12 @@ void *H5E_auto_data_g = NULL; /* Static function declarations */ +static herr_t H5E_init_interface (void); +#ifndef NEW_ERR +static hid_t H5E_register_class(const char *cls_name, const char *lib_name, + const char *version); +static hid_t H5E_unregister_class(H5E_cls_t *cls); +#endif /* NEW_ERR */ static herr_t H5E_walk_cb (int n, H5E_error_t *err_desc, void *client_data); @@ -302,8 +319,9 @@ H5E_init_interface(void) FUNC_ENTER_NOINIT(H5E_init_interface); /* Initialize the atom group for the dataset IDs */ - H5I_init_group(H5I_ERROR_CLASS, H5I_ERRORCLS_HASHSIZE, H5E_RESERVED_ATOMS, - (H5I_free_t)H5E_unregister_class); + if(H5I_init_group(H5I_ERROR_CLASS, H5I_ERRORCLS_HASHSIZE, H5E_ERRCLS_RESERVED_ATOMS, + (H5I_free_t)H5E_unregister_class)<0) + HGOTO_ERROR (H5E_ERROR, H5E_CANTINIT, FAIL, "unable to initialize interface"); /* From the old function; take out later */ H5E_auto_data_g = stderr; @@ -344,7 +362,7 @@ H5E_init_interface (void) #endif /* NEW_ERR */ #ifndef NEW_ERR - + /*------------------------------------------------------------------------- * Function: H5Eregister_class * @@ -374,6 +392,7 @@ done: FUNC_LEAVE_API(ret_value); } + /*------------------------------------------------------------------------- * Function: H5E_register_class * @@ -388,7 +407,7 @@ done: * *------------------------------------------------------------------------- */ -hid_t +static hid_t H5E_register_class(const char *cls_name, const char *lib_name, const char *version) { hid_t ret_value; /* Return value */ @@ -396,24 +415,27 @@ H5E_register_class(const char *cls_name, const char *lib_name, const char *versi FUNC_ENTER_NOAPI(H5E_register_class, FAIL); - cls = HDmalloc(sizeof(H5E_cls_t)); - - cls->cls_name = (char*)HDmalloc(sizeof(char)*(HDstrlen(cls_name)+1)); - HDstrcpy(cls->cls_name, cls_name); + /* Check arguments */ + assert(cls_name); + assert(lib_name); + assert(version); - cls->lib_name = HDmalloc(sizeof(char)*(strlen(lib_name)+1)); - HDstrcpy(cls->lib_name, lib_name); + /* Need to check for failures from malloc & strdup */ + cls = H5MM_malloc(sizeof(H5E_cls_t)); - cls->lib_vers = HDmalloc(sizeof(char)*(strlen(version)+1)); - HDstrcpy(cls->lib_vers, version); + cls->cls_name = HDstrdup(cls_name); + cls->lib_name = HDstrdup(lib_name); + cls->lib_vers = HDstrdup(version); /* Register the new error class to get an ID for it */ + /* Need to check for error */ ret_value = H5I_register(H5I_ERROR_CLASS, cls); done: FUNC_LEAVE_NOAPI(ret_value); } + /*------------------------------------------------------------------------- * Function: H5Eunregister_class * @@ -437,18 +459,21 @@ H5Eunregister_class(hid_t class_id) FUNC_ENTER_API(H5Eunregister_class, FAIL); H5TRACE1("e","i",class_id); + /* Need to check for errors */ cls = H5I_object_verify(class_id, H5I_ERROR_CLASS); /* * Decrement the counter on the dataset. It will be freed if the count * reaches zero. */ + /* Need to check for errors */ H5I_dec_ref(class_id); done: FUNC_LEAVE_API(ret_value); } + /*------------------------------------------------------------------------- * Function: H5E_unregister_class * @@ -463,26 +488,23 @@ done: * *------------------------------------------------------------------------- */ -hid_t +static hid_t H5E_unregister_class(H5E_cls_t *cls) { herr_t ret_value = SUCCEED; /* Return value */ FUNC_ENTER_NOAPI(H5E_unregister_class, FAIL); - HDfree(cls->cls_name); - HDfree(cls->lib_name); - HDfree(cls->lib_vers); - HDfree(cls); + H5MM_xfree(cls->cls_name); + H5MM_xfree(cls->lib_name); + H5MM_xfree(cls->lib_vers); + H5MM_xfree(cls); done: FUNC_LEAVE_NOAPI(ret_value); } - #endif /* NEW_ERR */ - - /*------------------------------------------------------------------------- * Function: H5Eset_auto diff --git a/src/H5Eprivate.h b/src/H5Eprivate.h index 228ebc0..58a7acf 100644 --- a/src/H5Eprivate.h +++ b/src/H5Eprivate.h @@ -27,7 +27,24 @@ #ifndef NEW_ERR -#define H5E_RESERVED_ATOMS 0 +#define H5E_ERRCLS_RESERVED_ATOMS 0 + +typedef struct H5E_cls_t { + char *cls_name; + char *lib_name; + char *lib_vers; +} H5E_cls_t; + +typedef struct H5E_maj_t { + char *mesg; + H5E_cls_t *cls; +} H5E_maj_t; + +typedef struct H5E_min_t { + char *mesg; + H5E_cls_t *cls; +} H5E_min_t; + #ifdef TMP /* HDF5 error class */ #define H5E_CLS_NAME "HDF5" @@ -36,146 +53,147 @@ /* HDF5 error class: major errors */ #define H5E_NONE_MAJOR_MSG "No error" -#define H5E_ARGS_MSG "Function arguments" -#define H5E_RESOURCE_MSG "Resource unavailable" -#define H5E_INTERNAL_MSG "Internal HDF5 error" -#define H5E_FILE_MSG "File interface" -#define H5E_IO_MSG "Low-level I/O layer" -#define H5E_FUNC_MSG "Function entry/exit" -#define H5E_ATOM_MSG "Atom layer" -#define H5E_CACHE_MSG "Meta data cache layer" -#define H5E_BTREE_MSG "B-tree layer" -#define H5E_SYM_MSG "Symbol table layer" -#define H5E_HEAP_MSG "Heap layer" -#define H5E_OHDR_MSG "Object header layer" -#define H5E_DATATYPE_MSG "Datatype interface" -#define H5E_DATASPACE_MSG "Dataspace interface" -#define H5E_DATASET_MSG "Dataset interface" -#define H5E_STORAGE_MSG "Data storage layer" -#define H5E_PLIST_MSG "Property list interface" -#define H5E_ATTR_MSG "Attribute layer" -#define H5E_PLINE_MSG "Data filters layer" -#define H5E_EFL_MSG "External file list" -#define H5E_REFERENCE_MSG "References layer" -#define H5E_VFL_MSG "Virtual File Layer" -#define H5E_TBBT_MSG "Threaded, Balanced, Binary Trees" -#define H5E_FPHDF5_MSG "Flexible Parallel HDF5" -#define H5E_TST_MSG "Ternary Search Trees" -#define H5E_RS_MSG "Reference Counted Strings" +#define H5E_MAJ_ARGS_MSG "Function arguments" +#define H5E_MAJ_RESOURCE_MSG "Resource unavailable" +#define H5E_MAJ_INTERNAL_MSG "Internal HDF5 error" +#define H5E_MAJ_FILE_MSG "File interface" +#define H5E_MAJ_IO_MSG "Low-level I/O layer" +#define H5E_MAJ_FUNC_MSG "Function entry/exit" +#define H5E_MAJ_ATOM_MSG "Atom layer" +#define H5E_MAJ_CACHE_MSG "Meta data cache layer" +#define H5E_MAJ_BTREE_MSG "B-tree layer" +#define H5E_MAJ_SYM_MSG "Symbol table layer" +#define H5E_MAJ_HEAP_MSG "Heap layer" +#define H5E_MAJ_OHDR_MSG "Object header layer" +#define H5E_MAJ_DATATYPE_MSG "Datatype interface" +#define H5E_MAJ_DATASPACE_MSG "Dataspace interface" +#define H5E_MAJ_DATASET_MSG "Dataset interface" +#define H5E_MAJ_STORAGE_MSG "Data storage layer" +#define H5E_MAJ_PLIST_MSG "Property list interface" +#define H5E_MAJ_ATTR_MSG "Attribute layer" +#define H5E_MAJ_PLINE_MSG "Data filters layer" +#define H5E_MAJ_EFL_MSG "External file list" +#define H5E_MAJ_REFERENCE_MSG "References layer" +#define H5E_MAJ_VFL_MSG "Virtual File Layer" +#define H5E_MAJ_TBBT_MSG "Threaded, Balanced, Binary Trees" +#define H5E_MAJ_FPHDF5_MSG "Flexible Parallel HDF5" +#define H5E_MAJ_TST_MSG "Ternary Search Trees" +#define H5E_MAJ_RS_MSG "Reference Counted Strings" +#define H5E_MAJ_ERROR_MSG "Error API" /* HDF5 error class: minor errors */ #define H5E_NONE_MINOR "No error" /* Argument errors */ -#define H5E_UNINITIALIZED_MSG "Information is uninitialized" -#define H5E_UNSUPPORTED_MSG "Feature is unsupported" -#define H5E_BADTYPE_MSG "Inappropriate type" -#define H5E_BADRANGE_MSG "Out of range" -#define H5E_BADVALUE_MSG "Bad value" +#define H5E_MIN_UNINITIALIZED_MSG "Information is uninitialized" +#define H5E_MIN_UNSUPPORTED_MSG "Feature is unsupported" +#define H5E_MIN_BADTYPE_MSG "Inappropriate type" +#define H5E_MIN_BADRANGE_MSG "Out of range" +#define H5E_MIN_BADVALUE_MSG "Bad value" /* Resource errors */ -#define H5E_NOSPACE_MSG "No space available for allocation" -#define H5E_CANTCOPY_MSG "Unable to copy object" -#define H5E_CANTFREE_MSG "Unable to free object" -#define H5E_ALREADYEXISTS_MSG "Object already exists" -#define H5E_CANTLOCK_MSG "Unable to lock object" -#define H5E_CANTUNLOCK_MSG "Unable to unlock object" -#define H5E_CANTGC_MSG "Unable to garbage collect" +#define H5E_MIN_NOSPACE_MSG "No space available for allocation" +#define H5E_MIN_CANTCOPY_MSG "Unable to copy object" +#define H5E_MIN_CANTFREE_MSG "Unable to free object" +#define H5E_MIN_ALREADYEXISTS_MSG "Object already exists" +#define H5E_MIN_CANTLOCK_MSG "Unable to lock object" +#define H5E_MIN_CANTUNLOCK_MSG "Unable to unlock object" +#define H5E_MIN_CANTGC_MSG "Unable to garbage collect" /* File accessability errors */ -#define H5E_FILEEXISTS_MSG "File already exists" -#define H5E_FILEOPEN_MSG "File already open" -#define H5E_CANTCREATE_MSG "Unable to create file" -#define H5E_CANTOPENFILE_MSG "Unable to open file" -#define H5E_CANTCLOSEFILE_MSG "Unable to close file" -#define H5E_NOTHDF5_MSG "Not an HDF5 file" -#define H5E_BADFILE_MSG "Bad file ID accessed" -#define H5E_TRUNCATED_MSG "File has been truncated" -#define H5E_MOUNT_MSG "File mount error" +#define H5E_MIN_FILEEXISTS_MSG "File already exists" +#define H5E_MIN_FILEOPEN_MSG "File already open" +#define H5E_MIN_CANTCREATE_MSG "Unable to create file" +#define H5E_MIN_CANTOPENFILE_MSG "Unable to open file" +#define H5E_MIN_CANTCLOSEFILE_MSG "Unable to close file" +#define H5E_MIN_NOTHDF5_MSG "Not an HDF5 file" +#define H5E_MIN_BADFILE_MSG "Bad file ID accessed" +#define H5E_MIN_TRUNCATED_MSG "File has been truncated" +#define H5E_MIN_MOUNT_MSG "File mount error" /* Generic low-level file I/O errors */ -#define H5E_SEEKERROR_MSG "Seek failed" -#define H5E_READERROR_MSG "Read failed" -#define H5E_WRITEERROR_MSG "Write failed" -#define H5E_CLOSEERROR_MSG "Close failed" -#define H5E_OVERFLOW_MSG "Address overflowed" -#define H5E_FCNTL_MSG "File control (fcntl) failed" +#define H5E_MIN_SEEKERROR_MSG "Seek failed" +#define H5E_MIN_READERROR_MSG "Read failed" +#define H5E_MIN_WRITEERROR_MSG "Write failed" +#define H5E_MIN_CLOSEERROR_MSG "Close failed" +#define H5E_MIN_OVERFLOW_MSG "Address overflowed" +#define H5E_MIN_FCNTL_MSG "File control (fcntl) failed" /* Function entry/exit interface errors */ -#define H5E_CANTINIT_MSG "Unable to initialize object" -#define H5E_ALREADYINIT_MSG "Object already initialized" -#define H5E_CANTRELEASE_MSG "Unable to release object" +#define H5E_MIN_CANTINIT_MSG "Unable to initialize object" +#define H5E_MIN_ALREADYINIT_MSG "Object already initialized" +#define H5E_MIN_CANTRELEASE_MSG "Unable to release object" /* Object atom related errors */ -#define H5E_BADATOM_MSG "Unable to find atom information (already closed?)" -#define H5E_BADGROUP_MSG "Unable to find ID group information" -#define H5E_CANTREGISTER_MSG "Unable to register new atom" -#define H5E_CANTINC_MSG "Unable to increment reference count" -#define H5E_CANTDEC_MSG "Unable to decrement reference count" -#define H5E_NOIDS_MSG "Out of IDs for group" +#define H5E_MIN_BADATOM_MSG "Unable to find atom information (already closed?)" +#define H5E_MIN_BADGROUP_MSG "Unable to find ID group information" +#define H5E_MIN_CANTREGISTER_MSG "Unable to register new atom" +#define H5E_MIN_CANTINC_MSG "Unable to increment reference count" +#define H5E_MIN_CANTDEC_MSG "Unable to decrement reference count" +#define H5E_MIN_NOIDS_MSG "Out of IDs for group" /* Cache related errors */ -#define H5E_CANTFLUSH_MSG "Unable to flush data from cache" -#define H5E_CANTLOAD_MSG "Unable to load meta data into cache" -#define H5E_PROTECT_MSG "Protected meta data error" -#define H5E_NOTCACHED_MSG "Meta data not currently cached" +#define H5E_MIN_CANTFLUSH_MSG "Unable to flush data from cache" +#define H5E_MIN_CANTLOAD_MSG "Unable to load meta data into cache" +#define H5E_MIN_PROTECT_MSG "Protected meta data error" +#define H5E_MIN_NOTCACHED_MSG "Meta data not currently cached" /* B-tree related errors */ -#define H5E_NOTFOUND_MSG "Object not found" -#define H5E_EXISTS_MSG "Object already exists" -#define H5E_CANTENCODE_MSG "Unable to encode value" -#define H5E_CANTDECODE_MSG "Unable to decode value" -#define H5E_CANTSPLIT_MSG "Unable to split node" -#define H5E_CANTINSERT_MSG "Unable to insert object" -#define H5E_CANTLIST_MSG "Unable to list node" +#define H5E_MIN_NOTFOUND_MSG "Object not found" +#define H5E_MIN_EXISTS_MSG "Object already exists" +#define H5E_MIN_CANTENCODE_MSG "Unable to encode value" +#define H5E_MIN_CANTDECODE_MSG "Unable to decode value" +#define H5E_MIN_CANTSPLIT_MSG "Unable to split node" +#define H5E_MIN_CANTINSERT_MSG "Unable to insert object" +#define H5E_MIN_CANTLIST_MSG "Unable to list node" /* Object header related errors */ -#define H5E_LINKCOUNT_MSG "Bad object header link count" -#define H5E_VERSION_MSG "Wrong version number" -#define H5E_ALIGNMENT_MSG "Alignment error" -#define H5E_BADMESG_MSG "Unrecognized message" -#define H5E_CANTDELETE_MSG "Can't delete message" +#define H5E_MIN_LINKCOUNT_MSG "Bad object header link count" +#define H5E_MIN_VERSION_MSG "Wrong version number" +#define H5E_MIN_ALIGNMENT_MSG "Alignment error" +#define H5E_MIN_BADMESG_MSG "Unrecognized message" +#define H5E_MIN_CANTDELETE_MSG "Can't delete message" /* Group related errors */ -#define H5E_CANTOPENOBJ_MSG "Can't open object" -#define H5E_COMPLEN_MSG "Name component is too long" -#define H5E_CWG_MSG "Problem with current working group" -#define H5E_LINK_MSG "Link count failure" -#define H5E_SLINK_MSG "Symbolic link error" +#define H5E_MIN_CANTOPENOBJ_MSG "Can't open object" +#define H5E_MIN_COMPLEN_MSG "Name component is too long" +#define H5E_MIN_CWG_MSG "Problem with current working group" +#define H5E_MIN_LINK_MSG "Link count failure" +#define H5E_MIN_SLINK_MSG "Symbolic link error" /* Datatype conversion errors */ -#define H5E_CANTCONVERT_MSG "Can't convert datatypes" -#define H5E_BADSIZE_MSG "Bad size for object" +#define H5E_MIN_CANTCONVERT_MSG "Can't convert datatypes" +#define H5E_MIN_BADSIZE_MSG "Bad size for object" /* Dataspace errors */ -#define H5E_CANTCLIP_MSG "Can't clip hyperslab region" -#define H5E_CANTCOUNT_MSG "Can't count elements" -#define H5E_CANTSELECT_MSG "Can't select hyperslab" -#define H5E_CANTNEXT_MSG "Can't move to next iterator location" -#define H5E_BADSELECT_MSG "Invalid selection" -#define H5E_CANTCOMPARE_MSG "Can't compare objects" +#define H5E_MIN_CANTCLIP_MSG "Can't clip hyperslab region" +#define H5E_MIN_CANTCOUNT_MSG "Can't count elements" +#define H5E_MIN_CANTSELECT_MSG "Can't select hyperslab" +#define H5E_MIN_CANTNEXT_MSG "Can't move to next iterator location" +#define H5E_MIN_BADSELECT_MSG "Invalid selection" +#define H5E_MIN_CANTCOMPARE_MSG "Can't compare objects" /* Property list errors */ -#define H5E_CANTGET_MSG "Can't get value" -#define H5E_CANTSET_MSG "Can't set value" -#define H5E_DUPCLASS_MSG "Duplicate class name in parent class" +#define H5E_MIN_CANTGET_MSG "Can't get value" +#define H5E_MIN_CANTSET_MSG "Can't set value" +#define H5E_MIN_DUPCLASS_MSG "Duplicate class name in parent class" /* Parallel MPI errors */ -#define H5E_MPI_MSG "Some MPI function failed" -#define H5E_MPIERRSTR_MSG "MPI Error String" +#define H5E_MIN_MPI_MSG "Some MPI function failed" +#define H5E_MIN_MPIERRSTR_MSG "MPI Error String" /* FPHDF5 errors */ -#define H5E_CANTMAKETREE_MSG "Can't create a binary tree node" -#define H5E_CANTRECV_MSG "Can't receive messages from processes" -#define H5E_CANTSENDMDATA_MSG "Can't send metadata message" -#define H5E_CANTCHANGE_MSG "Can't register change with server" -#define H5E_CANTALLOC_MSG "Can't allocate from file" +#define H5E_MIN_CANTMAKETREE_MSG "Can't create a binary tree node" +#define H5E_MIN_CANTRECV_MSG "Can't receive messages from processes" +#define H5E_MIN_CANTSENDMDATA_MSG "Can't send metadata message" +#define H5E_MIN_CANTCHANGE_MSG "Can't register change with server" +#define H5E_MIN_CANTALLOC_MSG "Can't allocate from file" /* I/O pipeline errors */ -#define H5E_NOFILTER_MSG "Requested filter is not available" -#define H5E_CALLBACK_MSG "Callback failed" -#define H5E_CANAPPLY_MSG "Error from filter \"can apply\" callback" -#define H5E_SETLOCAL_MSG "Error from filter \"set local\" callback" +#define H5E_MIN_NOFILTER_MSG "Requested filter is not available" +#define H5E_MIN_CALLBACK_MSG "Callback failed" +#define H5E_MIN_CANAPPLY_MSG "Error from filter \"can apply\" callback" +#define H5E_MIN_SETLOCAL_MSG "Error from filter \"set local\" callback" #endif /* TMP */ #endif /* NEW_ERR */ @@ -252,9 +270,6 @@ H5_DLLVAR const hbool_t H5E_clearable_g;/*safe to call H5E_clear() on enter?*/ H5_DLLVAR herr_t (*H5E_auto_g)(void *client_data); H5_DLLVAR void *H5E_auto_data_g; -H5_DLL hid_t H5E_register_class(const char *cls_name, const char *lib_name, - const char *version); -H5_DLL hid_t H5E_unregister_class(H5E_cls_t *cls); H5_DLL herr_t H5E_push (H5E_major_t maj_num, H5E_minor_t min_num, const char *func_name, const char *file_name, unsigned line, const char *desc); diff --git a/src/H5Epublic.h b/src/H5Epublic.h index 1cd8b09..9a46f1f 100644 --- a/src/H5Epublic.h +++ b/src/H5Epublic.h @@ -26,38 +26,31 @@ #ifndef NEW_ERR -typedef struct H5E_cls_t { - char *cls_name; - const char *lib_name; - const char *lib_vers; -} H5E_cls_t; - -typedef struct H5E_maj_t { - const char *mesg; - H5E_cls_t *cls; -} H5E_maj_t; - -typedef struct H5E_min_t { - const char *mesg; - H5E_cls_t *cls; -} H5E_min_t; - typedef enum H5E_msg_t { - H5E_ERROR =-1, - H5E_MAJOR, - H5E_MINOR, - H5E_LIMIT + H5E_MSG_ERROR =-1, + H5E_MSG_MAJOR, + H5E_MSG_MINOR, + H5E_MSG_LIMIT } H5E_msg_t; +/* When this header is included from H5Eprivate.h, don't make calls to H5open() */ +#undef H5OPEN +#ifndef _H5Eprivate_H +#define H5OPEN H5open(), +#else /* _H5Eprivate_H */ +#define H5OPEN +#endif /* _H5Eprivate_H */ + /* HDF5 error class */ -hid_t HDF5_ERR_CLS; +#define H5E_ERR_CLS (H5OPEN H5E_ERR_CLS_g) +H5_DLLVAR hid_t H5E_ERR_CLS_g; #ifdef TMP /* HDF5 error class: major errors. */ -hid_t H5E_NONE_MAJOR; /*special zero, no error */ +hid_t H5E_NONE_MAJOR; /*special zero, no error */ hid_t H5E_ARGS; /*invalid arguments to routine */ hid_t H5E_RESOURCE; /*resource unavailable */ -hid_t H5E_INTERNAL; /* Internal error (too specific to document in detail) */ +hid_t H5E_INTERNAL; /*Internal error (too specific to document in detail) */ hid_t H5E_FILE; /*file Accessability */ hid_t H5E_IO; /*Low-level I/O */ hid_t H5E_FUNC; /*function Entry/Exit */ @@ -81,6 +74,7 @@ hid_t H5E_TBBT; /*Threaded, Balanced, Binary Trees */ hid_t H5E_FPHDF5; /*Flexible Parallel HDF5 */ hid_t H5E_TST; /*Ternary Search Trees */ hid_t H5E_RS; /*Reference Counted Strings */ +hid_t H5E_ERROR; /*Error API */ /* HDF5 error class: minor errors. */ @@ -193,7 +187,7 @@ hid_t H5E_CANTALLOC; /*can't allocate from file hid_t H5E_NOFILTER; /*requested filter is not available */ hid_t H5E_CALLBACK; /*callback failed */ hid_t H5E_CANAPPLY; /*error from filter "can apply" callback */ -hid_t H5E_SETLOCAL /*error from filter "set local" callback */ +hid_t H5E_SETLOCAL; /*error from filter "set local" callback */ #endif /* TMP */ #endif /* NEW_ERR */ @@ -277,7 +271,8 @@ typedef enum H5E_major_t { H5E_TBBT, /*Threaded, Balanced, Binary Trees */ H5E_FPHDF5, /*Flexible Parallel HDF5 */ H5E_TST, /*Ternary Search Trees */ - H5E_RS /*Reference Counted Strings */ + H5E_RS, /*Reference Counted Strings */ + H5E_ERROR /*Error API */ } H5E_major_t; /* Declare an enumerated type which holds all the valid minor HDF error codes */ -- cgit v0.12