Skip to content

Commit cfec5a8

Browse files
authored
Unbreak build with CBF_ENABLE_ULP set (dials#92)
* Unbreak build with CBF_ENABLE_ULP set * Clarify conditional compilation MSVC does not understand it.
1 parent 16355cc commit cfec5a8

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

examples/testhdf5.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1121,11 +1121,13 @@ static testResult_t test_H5Dinsert
11211121
TEST_CBF_PASS(cbf_H5Dinsert(dset,off,std,cnt,buf,val,type));
11221122
{/* post-conditions */
11231123
CBF_CALL(cbf_H5Dread2(dset,off,std,cnt,valBuf,type));
1124-
if (CBF_SUCCESS==error) TEST(!cmp(val,valBuf,length
1124+
if (CBF_SUCCESS==error) {
11251125
#ifdef CBF_USE_ULP
1126-
,cmp_params
1126+
TEST(!cmp(val,valBuf,length,cmp_params));
1127+
#else
1128+
TEST(!cmp(val,valBuf,length));
11271129
#endif
1128-
));
1130+
}
11291131
}
11301132

11311133
return r;

src/cbf_hdf5.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26460,6 +26460,10 @@ static int process_DiffrnScanAxisCache(cbf_node * const category,
2646026460
const hsize_t max[] = {1};
2646126461
const hsize_t cnk[] = {1};
2646226462
hsize_t buf[] = {0};
26463+
#ifdef CBF_USE_ULP
26464+
cmp_double_param_t cmp_double_params;
26465+
void * cmp_params = &cmp_double_params;
26466+
#endif
2646326467

2646426468

2646526469
if (!handle || !h5handle || !matrix) return CBF_ARGUMENT;

0 commit comments

Comments
 (0)