diff options
author | Dana Robinson <43805+derobins@users.noreply.github.com> | 2023-04-25 17:03:41 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-25 17:03:41 (GMT) |
commit | 54f1c17bbe728b0fbef51bb6c6601746e51d2fbf (patch) | |
tree | 81372dd67df0230677ef2cfcf594e40802c32352 /src/H5Bprivate.h | |
parent | f909cb6c9b0f3eb0ddc77377065a9bc58ea6265c (diff) | |
download | hdf5-54f1c17bbe728b0fbef51bb6c6601746e51d2fbf.zip hdf5-54f1c17bbe728b0fbef51bb6c6601746e51d2fbf.tar.gz hdf5-54f1c17bbe728b0fbef51bb6c6601746e51d2fbf.tar.bz2 |
Harden the v1 B-tree and local heap cache clients (#2803)
* Hardens v1 B-tree deserialize function
* Harden the H5HL deserialize functionality
Diffstat (limited to 'src/H5Bprivate.h')
-rw-r--r-- | src/H5Bprivate.h | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/H5Bprivate.h b/src/H5Bprivate.h index 49e400c..0017c43 100644 --- a/src/H5Bprivate.h +++ b/src/H5Bprivate.h @@ -82,16 +82,16 @@ typedef int (*H5B_operator_t)(H5F_t *f, const void *_lt_key, haddr_t addr, const * the instances of nodes in that B-tree. */ typedef struct H5B_shared_t { - const struct H5B_class_t *type; /* Type of tree */ - unsigned two_k; /* 2*"K" value for tree's nodes */ - size_t sizeof_rkey; /* Size of raw (disk) key */ - size_t sizeof_rnode; /* Size of raw (disk) node */ - size_t sizeof_keys; /* Size of native (memory) key node */ - size_t sizeof_addr; /* Size of file address (in bytes) */ - size_t sizeof_len; /* Size of file lengths (in bytes) */ + const struct H5B_class_t *type; /* Type of tree */ + unsigned two_k; /* 2*"K" value for tree's nodes */ + size_t sizeof_rkey; /* Size of raw (disk) key */ + size_t sizeof_rnode; /* Size of raw (disk) node */ + size_t sizeof_keys; /* Size of native (memory) key node */ + size_t sizeof_addr; /* Size of file address (in bytes) */ + size_t sizeof_len; /* Size of file lengths (in bytes) */ uint8_t *page; /* Disk page */ size_t *nkey; /* Offsets of each native key in native key buffer */ - void *udata; /* 'Local' info for a B-tree */ + void *udata; /* 'Local' info for a B-tree */ } H5B_shared_t; /* @@ -101,7 +101,6 @@ typedef struct H5B_shared_t { * has an array of K values indexed by the `id' class field below. The * array is initialized with the HDF5_BTREE_K_DEFAULT macro. */ - typedef struct H5B_class_t { H5B_subid_t id; /*id as found in file*/ size_t sizeof_nkey; /*size of native (memory) key*/ |