diff options
Diffstat (limited to 'src/H5B.c')
-rw-r--r-- | src/H5B.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1796,11 +1796,11 @@ H5B_shared_new(const H5F_t *f, const H5B_class_t *type, size_t sizeof_rkey) #ifdef H5_CLEAR_MEMORY HDmemset(shared->page, 0, shared->sizeof_rnode); #endif /* H5_CLEAR_MEMORY */ - if(NULL == (shared->nkey = H5FL_SEQ_MALLOC(size_t, (size_t)(2 * H5F_KVALUE(f, type) + 1)))) + if(NULL == (shared->nkey = H5FL_SEQ_MALLOC(size_t, (size_t)(shared->two_k + 1)))) HGOTO_ERROR(H5E_BTREE, H5E_NOSPACE, NULL, "memory allocation failed for B-tree page") /* Initialize the offsets into the native key buffer */ - for(u = 0; u < (2 * H5F_KVALUE(f, type) + 1); u++) + for(u = 0; u < (shared->two_k + 1); u++) shared->nkey[u] = u * type->sizeof_nkey; /* Set return value */ |