summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorjhendersonHDF <jhenderson@hdfgroup.org>2023-07-18 11:27:07 (GMT)
committerGitHub <noreply@github.com>2023-07-18 11:27:07 (GMT)
commitaab497a6312a9d8434a7dc7b5a593713fc8fbce0 (patch)
tree018a95afb94dd103dcbef98e4a383382a52968bf /test
parent919ce7adc2f24414b749c2a6880da00259350881 (diff)
downloadhdf5-aab497a6312a9d8434a7dc7b5a593713fc8fbce0.zip
hdf5-aab497a6312a9d8434a7dc7b5a593713fc8fbce0.tar.gz
hdf5-aab497a6312a9d8434a7dc7b5a593713fc8fbce0.tar.bz2
Fix some warnings in developer builds (#3247)
* Fix some warnings in developer builds * Switch approach to Winline flag
Diffstat (limited to 'test')
-rw-r--r--test/chunk_info.c4
-rw-r--r--test/h5test.c3
-rw-r--r--test/onion.c3
-rw-r--r--test/stab.c3
4 files changed, 3 insertions, 10 deletions
diff --git a/test/chunk_info.c b/test/chunk_info.c
index 4a62458..cb79dc1 100644
--- a/test/chunk_info.c
+++ b/test/chunk_info.c
@@ -116,10 +116,6 @@ static const char *FILENAME[] = {"tchunk_info_earliest",
/* For compressed data */
#define DEFLATE_SIZE_ADJUST(s) (ceil(((double)(s)) * 1.001) + 12.0)
-/* For use in error reporting */
-#define MSG_CHK_ADDR "Chunk address should not be HADDR_UNDEF because of H5D_ALLOC_TIME_EARLY."
-#define MSG_CHK_SIZE "Chunk size should not be 0 because of H5D_ALLOC_TIME_EARLY."
-
/* Utility function to initialize arguments */
void reinit_vars(unsigned *read_flt_msk, haddr_t *addr, hsize_t *size);
diff --git a/test/h5test.c b/test/h5test.c
index 7d5ba66..70e81cc 100644
--- a/test/h5test.c
+++ b/test/h5test.c
@@ -85,9 +85,6 @@ MPI_Info h5_io_info_g = MPI_INFO_NULL; /* MPI INFO object for IO */
*/
static const char *multi_letters = "msbrglo";
-/* Length of multi-file VFD filename buffers */
-#define H5TEST_MULTI_FILENAME_LEN 1024
-
/* Temporary file for sending signal messages */
#define TMP_SIGNAL_FILE "tmp_signal_file"
diff --git a/test/onion.c b/test/onion.c
index 50a4aa7..eb44a4f 100644
--- a/test/onion.c
+++ b/test/onion.c
@@ -36,7 +36,6 @@
#define ONION_TEST_PAGE_SIZE_1 4
#define ONION_TEST_PAGE_SIZE_5 32
-#define ONION_TEST_BASENAME_SIZE 32
#define ONION_TEST_FIXNAME_SIZE 1024
#define ONION_TEST_EXPECTED_HISTORY_REVISIONS_MAX 16
#define ONION_TEST_REV_REV_WRITES_MAX 8
@@ -1309,6 +1308,7 @@ test_revision_record_encode_decode(void)
uint64_t size_ret;
H5FD_onion_revision_record_t r_out;
uint32_t checksum = 0;
+ hbool_t badness = FALSE;
char comment[25] = "Example comment message.";
H5FD_onion_revision_record_t record = {
H5FD_ONION_REVISION_RECORD_VERSION_CURR,
@@ -1384,7 +1384,6 @@ test_revision_record_encode_decode(void)
if (H5FD__onion_revision_record_encode(&record, buf, &checksum) != exp_size)
TEST_ERROR;
- hbool_t badness = FALSE;
for (i = 0; i < exp_size; i++) {
if (exp[i] != buf[i]) {
badness = TRUE;
diff --git a/test/stab.c b/test/stab.c
index acfe090..6bdba65 100644
--- a/test/stab.c
+++ b/test/stab.c
@@ -188,6 +188,7 @@ test_long(hid_t fcpl, hid_t fapl, hbool_t new_format)
{
hid_t fid = (-1); /* File ID */
hid_t g1 = (-1), g2 = (-1);
+ size_t name2Len;
char *name1 = NULL, *name2 = NULL;
char filename[NAME_BUF_SIZE];
size_t i;
@@ -207,7 +208,7 @@ test_long(hid_t fcpl, hid_t fapl, hbool_t new_format)
for (i = 0; i < LONG_NAME_LEN; i++)
name1[i] = (char)('A' + i % 26);
name1[LONG_NAME_LEN - 1] = '\0';
- size_t name2Len = (2 * LONG_NAME_LEN) + 2;
+ name2Len = (2 * LONG_NAME_LEN) + 2;
name2 = (char *)malloc(name2Len);
HDsnprintf(name2, name2Len, "%s/%s", name1, name1);