diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2009-10-02 02:08:59 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2009-10-02 02:08:59 (GMT) |
commit | 37ec6dc75e85ebd7f9fb9b32fe978e47ab3fe918 (patch) | |
tree | 387658306d99e60d807c2eb8b3888a12aca4a75f /src/H5Pdeprec.c | |
parent | 006071f2338faa14f2784562279cb78b4341bce0 (diff) | |
download | hdf5-37ec6dc75e85ebd7f9fb9b32fe978e47ab3fe918.zip hdf5-37ec6dc75e85ebd7f9fb9b32fe978e47ab3fe918.tar.gz hdf5-37ec6dc75e85ebd7f9fb9b32fe978e47ab3fe918.tar.bz2 |
[svn-r17582] Description:
Bring changes from file free space branch back to the trunk. *yay!*
Tested on:
FreeBSD/32 6.3 (duty) in debug mode
FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode
Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x,
w/C++ & FORTRAN, w/threadsafe, in debug mode
Linux/64-amd64 2.6 (smirom) w/Intel compilers, w/default API=1.6.x,
w/C++ & FORTRAN, in production mode
Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
w/szip filter, in production mode
Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN,
in production mode
Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in debug mode
Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode
Mac OS X/32 10.5.8 (amazon) in debug mode
Mac OS X/32 10.5.8 (amazon) w/C++ & FORTRAN, w/threadsafe,
in production mode
Diffstat (limited to 'src/H5Pdeprec.c')
-rw-r--r-- | src/H5Pdeprec.c | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/src/H5Pdeprec.c b/src/H5Pdeprec.c index 208fcb2..5c72247 100644 --- a/src/H5Pdeprec.c +++ b/src/H5Pdeprec.c @@ -440,5 +440,59 @@ H5Pinsert1(hid_t plist_id, const char *name, size_t size, void *value, done: FUNC_LEAVE_API(ret_value); } /* H5Pinsert1() */ + + +/*------------------------------------------------------------------------- + * Function: H5Pget_version + * + * Purpose: Retrieves version information for various parts of a file. + * + * SUPER: The file super block. + * FREELIST: The global free list. + * STAB: The root symbol table entry. + * SHHDR: Shared object headers. + * + * Any (or even all) of the output arguments can be null + * pointers. + * + * Return: Success: Non-negative, version information is returned + * through the arguments. + * + * Failure: Negative + * + * Programmer: Robb Matzke + * Wednesday, January 7, 1998 + * + *------------------------------------------------------------------------- + */ +herr_t +H5Pget_version(hid_t plist_id, unsigned *super/*out*/, unsigned *freelist/*out*/, + unsigned *stab/*out*/, unsigned *shhdr/*out*/) +{ + H5P_genplist_t *plist; /* Property list pointer */ + herr_t ret_value = SUCCEED; /* Return value */ + + FUNC_ENTER_API(H5Pget_version, FAIL) + H5TRACE5("e", "ixxxx", plist_id, super, freelist, stab, shhdr); + + /* Get the plist structure */ + if(NULL == (plist = H5P_object_verify(plist_id,H5P_FILE_CREATE))) + HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID") + + /* Get values */ + if(super) + if(H5P_get(plist, H5F_CRT_SUPER_VERS_NAME, super) < 0) + HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get superblock version") + if(freelist) + *freelist = HDF5_FREESPACE_VERSION; /* (hard-wired) */ + if(stab) + *stab = HDF5_OBJECTDIR_VERSION; /* (hard-wired) */ + if(shhdr) + *shhdr = HDF5_SHAREDHEADER_VERSION; /* (hard-wired) */ + +done: + FUNC_LEAVE_API(ret_value) +} /* end H5Pget_version() */ + #endif /* H5_NO_DEPRECATED_SYMBOLS */ |