diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2003-08-11 12:43:04 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2003-08-11 12:43:04 (GMT) |
commit | ed92f54f9bae998ffe1f686f4f4ea61cd4bbdade (patch) | |
tree | f60eb3cc97b756e34c63a20f030dd981ea44df85 /src/H5R.c | |
parent | 8de0645dfa17c22f6a8ee58361f7d4b7ce2755ae (diff) | |
download | hdf5-ed92f54f9bae998ffe1f686f4f4ea61cd4bbdade.zip hdf5-ed92f54f9bae998ffe1f686f4f4ea61cd4bbdade.tar.gz hdf5-ed92f54f9bae998ffe1f686f4f4ea61cd4bbdade.tar.bz2 |
[svn-r7334] Purpose:
Bug fix
Description:
Object references were not getting written out correctly to the file, with
recent changes to their memory structure.
Solution:
Convert the object references correctly.
Platforms tested:
h5committested
Diffstat (limited to 'src/H5R.c')
-rw-r--r-- | src/H5R.c | 17 |
1 files changed, 4 insertions, 13 deletions
@@ -157,11 +157,8 @@ H5R_create(void *_ref, H5G_entry_t *loc, const char *name, H5R_type_t ref_type, case H5R_OBJECT: { hobj_ref_t *ref=(hobj_ref_t *)_ref; /* Get pointer to correct type of reference struct */ - uint8_t *p; /* Pointer to OID to store */ - /* Set information for reference */ - p=(uint8_t *)ref; - H5F_addr_encode(loc->file,&p,sb.objno); + *ref=sb.objno; break; } @@ -351,13 +348,8 @@ H5R_dereference(H5F_t *file, hid_t dxpl_id, H5R_type_t ref_type, void *_ref) case H5R_OBJECT: { hobj_ref_t *ref=(hobj_ref_t *)_ref; /* Only object references currently supported */ - /* - * Switch on object type, when we implement that feature, always try to - * open a dataset for now - */ - /* Get the object oid */ - p=(uint8_t *)ref; - H5F_addr_decode(ent.file,(const uint8_t **)&p,&(ent.header)); + + ent.header=*ref; } /* end case */ break; @@ -666,8 +658,7 @@ H5R_get_obj_type(H5F_t *file, hid_t dxpl_id, H5R_type_t ref_type, void *_ref) hobj_ref_t *ref=(hobj_ref_t *)_ref; /* Only object references currently supported */ /* Get the object oid */ - p=(uint8_t *)ref; - H5F_addr_decode(ent.file,(const uint8_t **)&p,&(ent.header)); + ent.header=*ref; } /* end case */ break; |