summaryrefslogtreecommitdiffstats
path: root/src/H5Toh.c
diff options
context:
space:
mode:
authorMohamad Chaarawi <chaarawi@hdfgroup.org>2012-06-29 17:28:10 (GMT)
committerMohamad Chaarawi <chaarawi@hdfgroup.org>2012-06-29 17:28:10 (GMT)
commit358cac8ec8cd1989bf0b47d255751c6d4130c0fc (patch)
tree50907abf9364fed3f8067de4f7064bc9a4f66ced /src/H5Toh.c
parent5f34b5703d93fd795f136054a191008affb80011 (diff)
downloadhdf5-358cac8ec8cd1989bf0b47d255751c6d4130c0fc.zip
hdf5-358cac8ec8cd1989bf0b47d255751c6d4130c0fc.tar.gz
hdf5-358cac8ec8cd1989bf0b47d255751c6d4130c0fc.tar.bz2
[svn-r22502] implement named datatypes solution in object headers
modify datatype open and get_binary callbacks to be disjoint
Diffstat (limited to 'src/H5Toh.c')
-rw-r--r--src/H5Toh.c14
1 files changed, 0 insertions, 14 deletions
diff --git a/src/H5Toh.c b/src/H5Toh.c
index e76070f..7961706 100644
--- a/src/H5Toh.c
+++ b/src/H5Toh.c
@@ -27,7 +27,6 @@
#include "H5private.h" /* Generic Functions */
#include "H5Eprivate.h" /* Error handling */
#include "H5Iprivate.h" /* IDs */
-#include "H5MMprivate.h" /* Memory management */
#include "H5Opkg.h" /* Object headers */
#include "H5Tpkg.h" /* Datatypes */
@@ -133,9 +132,6 @@ done:
static hid_t
H5O_dtype_open(const H5G_loc_t *obj_loc, hid_t UNUSED lapl_id, hid_t dxpl_id, hbool_t app_ref)
{
- size_t nalloc;
- unsigned char *buf = NULL;
- void *dt = NULL; /* datatype token from VOL plugin */
H5T_t *type = NULL; /* Datatype opened */
hid_t ret_value; /* Return value */
@@ -147,16 +143,6 @@ H5O_dtype_open(const H5G_loc_t *obj_loc, hid_t UNUSED lapl_id, hid_t dxpl_id, hb
if(NULL == (type = H5T_open(obj_loc, dxpl_id)))
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTOPENOBJ, FAIL, "unable to open datatype")
- if(H5T_encode(type, NULL, &nalloc) < 0)
- HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "can't determine serialized length of datatype")
- buf = (unsigned char *) H5MM_malloc (nalloc);
- if(H5T_encode(type, buf, &nalloc) < 0)
- HGOTO_ERROR(H5E_DATATYPE, H5E_BADTYPE, FAIL, "can't serialize datatype")
- if(NULL == (dt = H5T_decode(buf)))
- HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "can't decode datatype")
- type->vol_obj = dt;
- H5MM_free(buf);
-
/* Register an ID for the datatype */
if((ret_value = H5I_register(H5I_DATATYPE, type, app_ref)) < 0)
HGOTO_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL, "unable to register datatype")