mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-04-18 17:40:55 +08:00
Merge pull request #2153 in HDFFV/hdf5 from ~BYRN/hdf5_adb:develop to develop
* commit 'ac87f12afe73fa22dcf31d9aeba05a259e215765': Remove const Fix compile error - declaration after executable statement Adjust cache.c only variables. Fix include to correct memory calls - big-endian issue.
This commit is contained in:
commit
817235bb60
40
test/cache.c
40
test/cache.c
@ -18,24 +18,38 @@
|
||||
* H5C.c
|
||||
*/
|
||||
#include "cache_common.h"
|
||||
#include "H5MFprivate.h"
|
||||
|
||||
|
||||
H5C_t * saved_cache = NULL; /* store the pointer to the instance of
|
||||
* of H5C_t created by H5Fcreate()
|
||||
* here between test cache setup and
|
||||
* shutdown.
|
||||
*/
|
||||
|
||||
haddr_t saved_actual_base_addr = HADDR_UNDEF; /* Store the address of the
|
||||
* space allocated for cache items in the file between
|
||||
* cache setup & takedown
|
||||
*/
|
||||
|
||||
hid_t saved_fapl_id = H5P_DEFAULT; /* store the fapl id here between
|
||||
* cache setup and takedown. Note
|
||||
* that if saved_fapl_id == H5P_DEFAULT,
|
||||
* we assume that there is no fapl to
|
||||
* close.
|
||||
*/
|
||||
* cache setup and takedown. Note
|
||||
* that if saved_fapl_id == H5P_DEFAULT,
|
||||
* we assume that there is no fapl to
|
||||
* close.
|
||||
*/
|
||||
|
||||
hid_t saved_fcpl_id = H5P_DEFAULT; /* store the fcpl id here between
|
||||
* cache setup and takedown. Note
|
||||
* that if saved_fcpl_id == H5P_DEFAULT,
|
||||
* we assume that there is no fcpl to
|
||||
* close.
|
||||
*/
|
||||
hid_t saved_fid = -1; /* store the file id here between cache setup
|
||||
* and takedown.
|
||||
*/
|
||||
* cache setup and takedown. Note
|
||||
* that if saved_fcpl_id == H5P_DEFAULT,
|
||||
* we assume that there is no fcpl to
|
||||
* close.
|
||||
*/
|
||||
|
||||
hid_t saved_fid = -1; /* store the file id here between cache setup
|
||||
* and takedown.
|
||||
*/
|
||||
hbool_t write_permitted = TRUE;
|
||||
hbool_t try_core_file_driver = FALSE;
|
||||
hbool_t core_file_driver_failed = FALSE;
|
||||
|
||||
|
@ -18,23 +18,10 @@
|
||||
* implemented in H5C.c
|
||||
*/
|
||||
#include "H5CXprivate.h" /* API Contexts */
|
||||
#include "H5MFprivate.h"
|
||||
#include "H5MMprivate.h"
|
||||
|
||||
#include "cache_common.h"
|
||||
|
||||
|
||||
H5C_t * saved_cache = NULL; /* store the pointer to the instance of
|
||||
* of H5C_t created by H5Fcreate()
|
||||
* here between test cache setup and
|
||||
* shutdown.
|
||||
*/
|
||||
|
||||
haddr_t saved_actual_base_addr = HADDR_UNDEF; /* Store the address of the
|
||||
space allocated for cache items in the file between
|
||||
cache setup & takedown */
|
||||
|
||||
hbool_t write_permitted = TRUE;
|
||||
hbool_t pass = TRUE; /* set to false on error */
|
||||
const char *failure_mssg = NULL;
|
||||
|
||||
|
@ -538,10 +538,6 @@ struct expected_entry_status
|
||||
|
||||
|
||||
/* global variable externs: */
|
||||
H5TEST_DLLVAR H5C_t * saved_cache;
|
||||
|
||||
H5TEST_DLLVAR haddr_t saved_actual_base_addr;
|
||||
H5TEST_DLLVAR hbool_t write_permitted;
|
||||
H5TEST_DLLVAR hbool_t pass; /* set to false on error */
|
||||
H5TEST_DLLVAR const char *failure_mssg;
|
||||
|
||||
|
@ -7065,6 +7065,7 @@ static void
|
||||
make_random_offset_and_increment(long nelts, long *offsetp, long *incp)
|
||||
{
|
||||
long inc;
|
||||
long maxinc;
|
||||
|
||||
HDassert(0 < nelts);
|
||||
|
||||
@ -7073,7 +7074,7 @@ make_random_offset_and_increment(long nelts, long *offsetp, long *incp)
|
||||
/* `maxinc` is chosen so that for any `x` in [0, nelts - 1],
|
||||
* `x + maxinc` does not overflow a long.
|
||||
*/
|
||||
const long maxinc = MIN(nelts - 1, LONG_MAX - nelts);
|
||||
maxinc = MIN(nelts - 1, LONG_MAX - nelts);
|
||||
|
||||
/* Choose a random number in [1, nelts - 1]. If its greatest divisor
|
||||
* in common with `nelts` is 1, then it will "generate" the additive ring
|
||||
@ -13132,7 +13133,7 @@ test_versionbounds(void)
|
||||
return FAIL;
|
||||
} /* end test_versionbounds() */
|
||||
|
||||
|
||||
|
||||
/*-----------------------------------------------------------------------------
|
||||
* Function: test_object_header_minimization_dcpl
|
||||
*
|
||||
|
Loading…
x
Reference in New Issue
Block a user