diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/H5Aint.c | 2 | ||||
-rw-r--r-- | src/H5B2cache.c | 6 | ||||
-rw-r--r-- | src/H5B2int.c | 2 | ||||
-rw-r--r-- | src/H5EAcache.c | 2 | ||||
-rw-r--r-- | src/H5FAcache.c | 2 | ||||
-rw-r--r-- | src/H5FScache.c | 2 | ||||
-rw-r--r-- | src/H5Fprivate.h | 3 | ||||
-rw-r--r-- | src/H5HFtest.c | 2 | ||||
-rw-r--r-- | src/H5Oainfo.c | 2 | ||||
-rw-r--r-- | src/H5Oattr.c | 14 | ||||
-rw-r--r-- | src/H5Ofill.c | 4 | ||||
-rw-r--r-- | src/H5Ofsinfo.c | 10 | ||||
-rw-r--r-- | src/H5Oginfo.c | 10 | ||||
-rw-r--r-- | src/H5Oint.c | 2 | ||||
-rw-r--r-- | src/H5Olayout.c | 2 | ||||
-rw-r--r-- | src/H5Olinfo.c | 2 | ||||
-rw-r--r-- | src/H5Olink.c | 18 | ||||
-rw-r--r-- | src/H5Osdspace.c | 14 | ||||
-rw-r--r-- | src/H5Rint.c | 2 | ||||
-rw-r--r-- | src/H5SMcache.c | 17 | ||||
-rw-r--r-- | src/H5SMmessage.c | 8 | ||||
-rw-r--r-- | src/H5Shyper.c | 6 | ||||
-rw-r--r-- | src/H5Tbit.c | 10 |
23 files changed, 72 insertions, 70 deletions
diff --git a/src/H5Aint.c b/src/H5Aint.c index ecbbd48..54c17ee 100644 --- a/src/H5Aint.c +++ b/src/H5Aint.c @@ -2026,7 +2026,7 @@ H5A__set_version(const H5F_t *f, H5A_t *attr) version = H5O_ATTR_VERSION_1; /* Write out basic version */ /* Upgrade to the version indicated by the file's low bound if higher */ - ASSIGN_TO_SMALLER_SIZE(version, uint8_t, MAX(version, (uint8_t)H5O_attr_ver_bounds[H5F_LOW_BOUND(f)]), int); + H5_CHECKED_ASSIGN(version, uint8_t, MAX(version, (uint8_t)H5O_attr_ver_bounds[H5F_LOW_BOUND(f)]), int); /* Version bounds check */ if(version > H5O_attr_ver_bounds[H5F_HIGH_BOUND(f)]) diff --git a/src/H5B2cache.c b/src/H5B2cache.c index fe4827d..7d163bf 100644 --- a/src/H5B2cache.c +++ b/src/H5B2cache.c @@ -398,7 +398,7 @@ H5B2__cache_hdr_serialize(const H5F_t *f, void *_image, size_t H5_ATTR_UNUSED le *image++ = H5B2_HDR_VERSION; /* B-tree type */ - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, hdr->cls->id, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, hdr->cls->id, int); /* Node size (in bytes) */ UINT32ENCODE(image, hdr->node_size); @@ -818,7 +818,7 @@ H5B2__cache_int_serialize(const H5F_t *f, void *_image, size_t H5_ATTR_UNUSED le *image++ = H5B2_INT_VERSION; /* B-tree type */ - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, internal->hdr->cls->id, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, internal->hdr->cls->id, int); HDassert((size_t)(image - (uint8_t *)_image) == (H5B2_INT_PREFIX_SIZE - H5B2_SIZEOF_CHKSUM)); /* Serialize records for internal node */ @@ -1219,7 +1219,7 @@ H5B2__cache_leaf_serialize(const H5F_t H5_ATTR_UNUSED *f, void *_image, size_t H *image++ = H5B2_LEAF_VERSION; /* B-tree type */ - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, leaf->hdr->cls->id, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, leaf->hdr->cls->id, int); HDassert((size_t)(image - (uint8_t *)_image) == (H5B2_LEAF_PREFIX_SIZE - H5B2_SIZEOF_CHKSUM)); /* Serialize records for leaf node */ diff --git a/src/H5B2int.c b/src/H5B2int.c index ff835eb..932f5f3 100644 --- a/src/H5B2int.c +++ b/src/H5B2int.c @@ -239,7 +239,7 @@ H5B2__split1(H5B2_hdr_t *hdr, uint16_t depth, H5B2_node_ptr_t *curr_node_ptr, old_node_nrec = internal->node_ptrs[idx].node_nrec; /* Determine "middle" record to promote to internal node */ - ASSIGN_TO_SMALLER_SIZE(mid_record, uint16_t, old_node_nrec / 2, int); + H5_CHECKED_ASSIGN(mid_record, uint16_t, old_node_nrec / 2, int); /* Copy "upper half" of records to new child */ H5MM_memcpy(H5B2_NAT_NREC(right_native, hdr, 0), diff --git a/src/H5EAcache.c b/src/H5EAcache.c index b51d29e..9a76f4a 100644 --- a/src/H5EAcache.c +++ b/src/H5EAcache.c @@ -487,7 +487,7 @@ H5EA__cache_hdr_serialize(const H5F_t *f, void *_image, size_t H5_ATTR_UNUSED le *image++ = H5EA_HDR_VERSION; /* Extensible array type */ - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, hdr->cparam.cls->id, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, hdr->cparam.cls->id, int); /* General array creation/configuration information */ *image++ = hdr->cparam.raw_elmt_size; /* Element size in file (in bytes) */ diff --git a/src/H5FAcache.c b/src/H5FAcache.c index 2b5187d..30d19e8 100644 --- a/src/H5FAcache.c +++ b/src/H5FAcache.c @@ -418,7 +418,7 @@ H5FA__cache_hdr_serialize(const H5F_t *f, void *_image, size_t H5_ATTR_UNUSED le /* Fixed array type */ *image++ = (uint8_t)hdr->cparam.cls->id; - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, hdr->cparam.cls->id, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, hdr->cparam.cls->id, int); /* General array creation/configuration information */ *image++ = hdr->cparam.raw_elmt_size; /* Element size in file (in bytes) */ diff --git a/src/H5FScache.c b/src/H5FScache.c index d4f77f4..28c35e4 100644 --- a/src/H5FScache.c +++ b/src/H5FScache.c @@ -735,7 +735,7 @@ H5FS__cache_hdr_serialize(const H5F_t *f, void *_image, size_t len, *image++ = H5FS_HDR_VERSION; /* Client ID */ - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, fspace->client, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, fspace->client, int); /* Total space tracked */ H5F_ENCODE_LENGTH(f, image, fspace->tot_space); diff --git a/src/H5Fprivate.h b/src/H5Fprivate.h index 0fe1867..d6410a7 100644 --- a/src/H5Fprivate.h +++ b/src/H5Fprivate.h @@ -29,7 +29,8 @@ typedef struct H5F_t H5F_t; #include "H5VLpublic.h" /* Virtual Object Layer */ /* Private headers needed by this file */ -#include "H5MMprivate.h" /* Memory management */ +#include "H5private.h" /* Generic Functions */ +#include "H5MMprivate.h" /* Memory management */ #ifdef H5_HAVE_PARALLEL #include "H5Pprivate.h" /* Property lists */ #endif /* H5_HAVE_PARALLEL */ diff --git a/src/H5HFtest.c b/src/H5HFtest.c index b0291b8..585a1bf 100644 --- a/src/H5HFtest.c +++ b/src/H5HFtest.c @@ -481,7 +481,7 @@ H5HF_get_id_type_test(const void *_id, unsigned char *obj_type) HDassert(obj_type); /* Get the type for a heap ID */ - ASSIGN_TO_SMALLER_SIZE(*obj_type, unsigned char, *id & H5HF_ID_TYPE_MASK, int); + H5_CHECKED_ASSIGN(*obj_type, unsigned char, *id & H5HF_ID_TYPE_MASK, int); FUNC_LEAVE_NOAPI(SUCCEED) } /* H5HF_get_id_type_test() */ diff --git a/src/H5Oainfo.c b/src/H5Oainfo.c index d923a9f..a0730e8 100644 --- a/src/H5Oainfo.c +++ b/src/H5Oainfo.c @@ -194,7 +194,7 @@ H5O_ainfo_encode(H5F_t *f, hbool_t H5_ATTR_UNUSED disable_shared, uint8_t *p, co *p++ = H5O_AINFO_VERSION; /* The flags for the attribute indices */ - ASSIGN_TO_SMALLER_SIZE(flags, unsigned char, ainfo->track_corder ? H5O_AINFO_TRACK_CORDER : 0, int); + H5_CHECKED_ASSIGN(flags, unsigned char, ainfo->track_corder ? H5O_AINFO_TRACK_CORDER : 0, int); flags = (unsigned char)(flags | (ainfo->index_corder ? H5O_AINFO_INDEX_CORDER : 0)); *p++ = flags; diff --git a/src/H5Oattr.c b/src/H5Oattr.c index 2697959..634069c 100644 --- a/src/H5Oattr.c +++ b/src/H5Oattr.c @@ -16,12 +16,12 @@ #define H5S_FRIEND /*suppress error about including H5Spkg */ -#include "H5private.h" /* Generic Functions */ -#include "H5Apkg.h" /* Attributes */ -#include "H5Eprivate.h" /* Error handling */ -#include "H5MMprivate.h" /* Memory management */ -#include "H5Opkg.h" /* Object headers */ -#include "H5Spkg.h" /* Dataspaces */ +#include "H5private.h" /* Generic Functions */ +#include "H5Apkg.h" /* Attributes */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5MMprivate.h" /* Memory management */ +#include "H5Opkg.h" /* Object headers */ +#include "H5Spkg.h" /* Dataspaces */ /* PRIVATE PROTOTYPES */ static herr_t H5O_attr_encode(H5F_t *f, uint8_t *p, const void *mesg); @@ -329,7 +329,7 @@ H5O_attr_encode(H5F_t *f, uint8_t *p, const void *mesg) /* The character encoding for the attribute's name, in later versions */ if(attr->shared->version >= H5O_ATTR_VERSION_3) { - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, attr->shared->encoding, int); + H5_CHECKED_ASSIGN(*p++, uint8_t, attr->shared->encoding, int); } /* Write the name including null terminator */ diff --git a/src/H5Ofill.c b/src/H5Ofill.c index 14b12db..93f2a65 100644 --- a/src/H5Ofill.c +++ b/src/H5Ofill.c @@ -408,10 +408,10 @@ H5O_fill_new_encode(H5F_t H5_ATTR_UNUSED *f, uint8_t *p, const void *_fill) if(fill->version < H5O_FILL_VERSION_3) { /* Space allocation time */ - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, fill->alloc_time, int); + H5_CHECKED_ASSIGN(*p++, uint8_t, fill->alloc_time, int); /* Fill value writing time */ - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, fill->fill_time, int); + H5_CHECKED_ASSIGN(*p++, uint8_t, fill->fill_time, int); /* Whether fill value is defined */ *p++ = (uint8_t)fill->fill_defined; diff --git a/src/H5Ofsinfo.c b/src/H5Ofsinfo.c index 82afa96..4bd8fff 100644 --- a/src/H5Ofsinfo.c +++ b/src/H5Ofsinfo.c @@ -25,11 +25,11 @@ #include "H5Omodule.h" /* This source code file is part of the H5O module */ -#include "H5private.h" /* Generic Functions */ -#include "H5Eprivate.h" /* Error handling */ +#include "H5private.h" /* Generic Functions */ +#include "H5Eprivate.h" /* Error handling */ #include "H5Fpkg.h" /* File access */ -#include "H5FLprivate.h" /* Free lists */ -#include "H5Opkg.h" /* Object headers */ +#include "H5FLprivate.h" /* Free lists */ +#include "H5Opkg.h" /* Object headers */ /* PRIVATE PROTOTYPES */ static void *H5O_fsinfo_decode(H5F_t *f, H5O_t *open_oh, unsigned mesg_flags, @@ -225,7 +225,7 @@ H5O_fsinfo_encode(H5F_t *f, hbool_t H5_ATTR_UNUSED disable_shared, uint8_t *p, c *p++ = (uint8_t)fsinfo->version; /* message version */ *p++ = (uint8_t)fsinfo->strategy; /* File space strategy */ - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, fsinfo->strategy, unsigned); + H5_CHECKED_ASSIGN(*p++, uint8_t, fsinfo->strategy, unsigned); *p++ = (unsigned char)fsinfo->persist; /* Free-space persist or not */ H5F_ENCODE_LENGTH(f, p, fsinfo->threshold); /* Free-space section size threshold */ diff --git a/src/H5Oginfo.c b/src/H5Oginfo.c index 027f33c..f4dfa6d 100644 --- a/src/H5Oginfo.c +++ b/src/H5Oginfo.c @@ -22,13 +22,13 @@ *------------------------------------------------------------------------- */ -#include "H5Omodule.h" /* This source code file is part of the H5O module */ +#include "H5Omodule.h" /* This source code file is part of the H5O module */ -#include "H5private.h" /* Generic Functions */ +#include "H5private.h" /* Generic Functions */ #include "H5Eprivate.h" /* Error handling */ -#include "H5FLprivate.h" /* Free lists */ -#include "H5Opkg.h" /* Object headers */ +#include "H5FLprivate.h" /* Free lists */ +#include "H5Opkg.h" /* Object headers */ /* PRIVATE PROTOTYPES */ @@ -183,7 +183,7 @@ H5O_ginfo_encode(H5F_t H5_ATTR_UNUSED *f, hbool_t H5_ATTR_UNUSED disable_shared, *p++ = H5O_GINFO_VERSION; /* The flags for the group info */ - ASSIGN_TO_SMALLER_SIZE(flags, unsigned char, ginfo->store_link_phase_change ? H5O_GINFO_STORE_PHASE_CHANGE : 0, int); + H5_CHECKED_ASSIGN(flags, unsigned char, ginfo->store_link_phase_change ? H5O_GINFO_STORE_PHASE_CHANGE : 0, int); flags = (unsigned char)(flags | (ginfo->store_est_entry_info ? H5O_GINFO_STORE_EST_ENTRY_INFO : 0)); *p++ = flags; diff --git a/src/H5Oint.c b/src/H5Oint.c index b923605..0e69bfa 100644 --- a/src/H5Oint.c +++ b/src/H5Oint.c @@ -239,7 +239,7 @@ H5O_set_version(H5F_t *f, H5O_t *oh, uint8_t oh_flags, hbool_t store_msg_crt_idx version = H5O_VERSION_1; /* Upgrade to the version indicated by the file's low bound if higher */ - ASSIGN_TO_SMALLER_SIZE(version, uint8_t, MAX(version, (uint8_t)H5O_obj_ver_bounds[H5F_LOW_BOUND(f)]), int); + H5_CHECKED_ASSIGN(version, uint8_t, MAX(version, (uint8_t)H5O_obj_ver_bounds[H5F_LOW_BOUND(f)]), int); /* Version bounds check */ if(version > H5O_obj_ver_bounds[H5F_HIGH_BOUND(f)]) diff --git a/src/H5Olayout.c b/src/H5Olayout.c index 143f49e..069ee7c 100644 --- a/src/H5Olayout.c +++ b/src/H5Olayout.c @@ -570,7 +570,7 @@ H5O__layout_encode(H5F_t *f, hbool_t H5_ATTR_UNUSED disable_shared, uint8_t *p, H5O_LAYOUT_VERSION_3 : mesg->version); /* Layout class */ - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, mesg->type, int); + H5_CHECKED_ASSIGN(*p++, uint8_t, mesg->type, int); /* Write out layout class specific information */ switch(mesg->type) { diff --git a/src/H5Olinfo.c b/src/H5Olinfo.c index f605e8e..9e57185 100644 --- a/src/H5Olinfo.c +++ b/src/H5Olinfo.c @@ -203,7 +203,7 @@ H5O_linfo_encode(H5F_t *f, hbool_t H5_ATTR_UNUSED disable_shared, uint8_t *p, co *p++ = H5O_LINFO_VERSION; /* The flags for the link indices */ - ASSIGN_TO_SMALLER_SIZE(index_flags, uint8_t, linfo->track_corder ? H5O_LINFO_TRACK_CORDER : 0, int); + H5_CHECKED_ASSIGN(index_flags, uint8_t, linfo->track_corder ? H5O_LINFO_TRACK_CORDER : 0, int); index_flags = (uint8_t)(index_flags | (linfo->index_corder ? H5O_LINFO_INDEX_CORDER : 0)); *p++ = index_flags; diff --git a/src/H5Olink.c b/src/H5Olink.c index 3453565..6076556 100644 --- a/src/H5Olink.c +++ b/src/H5Olink.c @@ -24,17 +24,17 @@ #define H5G_FRIEND /*suppress error about including H5Gpkg */ #define H5L_FRIEND /*suppress error about including H5Lpkg */ -#include "H5Omodule.h" /* This source code file is part of the H5O module */ +#include "H5Omodule.h" /* This source code file is part of the H5O module */ -#include "H5private.h" /* Generic Functions */ -#include "H5Eprivate.h" /* Error handling */ +#include "H5private.h" /* Generic Functions */ +#include "H5Eprivate.h" /* Error handling */ #include "H5FLprivate.h" /* Free lists */ -#include "H5Gpkg.h" /* Groups */ -#include "H5Iprivate.h" /* IDs */ -#include "H5Lpkg.h" /* Links */ -#include "H5MMprivate.h" /* Memory management */ -#include "H5Opkg.h" /* Object headers */ +#include "H5Gpkg.h" /* Groups */ +#include "H5Iprivate.h" /* IDs */ +#include "H5Lpkg.h" /* Links */ +#include "H5MMprivate.h" /* Memory management */ +#include "H5Opkg.h" /* Object headers */ /* PRIVATE PROTOTYPES */ @@ -316,7 +316,7 @@ H5O_link_encode(H5F_t *f, hbool_t H5_ATTR_UNUSED disable_shared, uint8_t *p, con /* Store the type of a non-default link */ if(link_flags & H5O_LINK_STORE_LINK_TYPE) - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, lnk->type, int); + H5_CHECKED_ASSIGN(*p++, uint8_t, lnk->type, int); /* Store the link creation order in the file, if its valid */ if(lnk->corder_valid) diff --git a/src/H5Osdspace.c b/src/H5Osdspace.c index 7b6c444..b7a95f5 100644 --- a/src/H5Osdspace.c +++ b/src/H5Osdspace.c @@ -15,13 +15,13 @@ #define H5S_FRIEND /*prevent warning from including H5Spkg.h */ #include "H5private.h" /* Generic Functions */ -#include "H5Dprivate.h" /* Datasets */ -#include "H5Eprivate.h" /* Error handling */ -#include "H5FLprivate.h" /* Free lists */ -#include "H5Gprivate.h" /* Groups */ +#include "H5Dprivate.h" /* Datasets */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5FLprivate.h" /* Free lists */ +#include "H5Gprivate.h" /* Groups */ #include "H5MMprivate.h" /* Memory management */ -#include "H5Opkg.h" /* Object headers */ -#include "H5Spkg.h" /* Dataspaces */ +#include "H5Opkg.h" /* Object headers */ +#include "H5Spkg.h" /* Dataspaces */ /* PRIVATE PROTOTYPES */ @@ -257,7 +257,7 @@ H5O_sdspace_encode(H5F_t *f, uint8_t *p, const void *_mesg) /* Dataspace type */ if(sdim->version > H5O_SDSPACE_VERSION_1) { - ASSIGN_TO_SMALLER_SIZE(*p++, uint8_t, sdim->type, int); + H5_CHECKED_ASSIGN(*p++, uint8_t, sdim->type, int); } else { *p++ = 0; /*reserved*/ diff --git a/src/H5Rint.c b/src/H5Rint.c index a318ddc..96f33ef 100644 --- a/src/H5Rint.c +++ b/src/H5Rint.c @@ -993,7 +993,7 @@ H5R__decode(const unsigned char *buf, size_t *nbytes, H5R_ref_priv_t *ref) HGOTO_ERROR(H5E_REFERENCE, H5E_CANTDECODE, FAIL, "Buffer size is too small") /* Set new reference */ - ASSIGN_TO_SMALLER_SIZE(ref->type, int8_t, (H5R_type_t)*p++, int); + H5_CHECKED_ASSIGN(ref->type, int8_t, (H5R_type_t)*p++, int); if(ref->type <= H5R_BADTYPE || ref->type >= H5R_MAXTYPE) HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid reference type") diff --git a/src/H5SMcache.c b/src/H5SMcache.c index 40692cd..448e128 100644 --- a/src/H5SMcache.c +++ b/src/H5SMcache.c @@ -32,13 +32,14 @@ /***********/ /* Headers */ /***********/ -#include "H5Eprivate.h" /* Error handling */ -#include "H5Fprivate.h" /* File access */ -#include "H5FLprivate.h" /* Free Lists */ -#include "H5MFprivate.h" /* File memory management */ -#include "H5MMprivate.h" /* Memory management */ -#include "H5SMpkg.h" /* Shared object header messages */ -#include "H5WBprivate.h" /* Wrapped Buffers */ +#include "H5private.h" /* Generic Functions */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5Fprivate.h" /* File access */ +#include "H5FLprivate.h" /* Free Lists */ +#include "H5MFprivate.h" /* File memory management */ +#include "H5MMprivate.h" /* Memory management */ +#include "H5SMpkg.h" /* Shared object header messages */ +#include "H5WBprivate.h" /* Wrapped Buffers */ /****************/ @@ -397,7 +398,7 @@ H5SM__cache_table_serialize(const H5F_t *f, void *_image, size_t len, *image++ = H5SM_LIST_VERSION; /* Is message index a list or a B-tree? */ - ASSIGN_TO_SMALLER_SIZE(*image++, uint8_t, table->indexes[u].index_type, int); + H5_CHECKED_ASSIGN(*image++, uint8_t, table->indexes[u].index_type, int); /* Type of messages in the index */ UINT16ENCODE(image, table->indexes[u].mesg_types); diff --git a/src/H5SMmessage.c b/src/H5SMmessage.c index 2a04423..9e1eee2 100644 --- a/src/H5SMmessage.c +++ b/src/H5SMmessage.c @@ -22,9 +22,9 @@ /***********/ /* Headers */ /***********/ -#include "H5private.h" /* Generic Functions */ -#include "H5Eprivate.h" /* Error handling */ -#include "H5MMprivate.h" /* Memory management */ +#include "H5private.h" /* Generic Functions */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5MMprivate.h" /* Memory management */ #include "H5Opkg.h" /* Object Headers */ #include "H5SMpkg.h" /* Shared object header messages */ @@ -298,7 +298,7 @@ H5SM__message_encode(uint8_t *raw, const void *_nrecord, void *_ctx) /* Sanity check */ HDassert(ctx); - ASSIGN_TO_SMALLER_SIZE(*raw++, uint8_t, message->location, int); + H5_CHECKED_ASSIGN(*raw++, uint8_t, message->location, int); UINT32ENCODE(raw, message->hash); if(message->location == H5SM_IN_HEAP) { diff --git a/src/H5Shyper.c b/src/H5Shyper.c index 0f73e7b..f3f9b9f 100644 --- a/src/H5Shyper.c +++ b/src/H5Shyper.c @@ -30,8 +30,8 @@ /***********/ #include "H5private.h" /* Generic Functions */ #include "H5CXprivate.h" /* API Contexts */ -#include "H5Eprivate.h" /* Error handling */ -#include "H5FLprivate.h" /* Free Lists */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5FLprivate.h" /* Free Lists */ #include "H5Iprivate.h" /* ID Functions */ #include "H5MMprivate.h" /* Memory management */ #include "H5Spkg.h" /* Dataspace functions */ @@ -3674,7 +3674,7 @@ H5S__hyper_get_version_enc_size(const H5S_t *space, hsize_t block_count, uint32_ /* Determine the encoding size */ enc2 = H5S__hyper_get_enc_size_real(max2); - ASSIGN_TO_SMALLER_SIZE(*enc_size, uint8_t, MAX(enc1, enc2), int); + H5_CHECKED_ASSIGN(*enc_size, uint8_t, MAX(enc1, enc2), int); } /* end if */ else { hsize_t max_size = block_count; diff --git a/src/H5Tbit.c b/src/H5Tbit.c index 1a7ea9b..d2f5657 100644 --- a/src/H5Tbit.c +++ b/src/H5Tbit.c @@ -21,9 +21,9 @@ #include "H5private.h" /*generic functions */ #include "H5Eprivate.h" /*error handling */ -#include "H5MMprivate.h" /* Memory management */ -#include "H5Tpkg.h" /*data-type functions */ -#include "H5WBprivate.h" /* Wrapped Buffers */ +#include "H5MMprivate.h" /* Memory management */ +#include "H5Tpkg.h" /*data-type functions */ +#include "H5WBprivate.h" /* Wrapped Buffers */ @@ -363,7 +363,7 @@ H5T__bit_set(uint8_t *buf, size_t offset, size_t size, hbool_t value) /* The middle bytes */ while (size >= 8) { - ASSIGN_TO_SMALLER_SIZE(buf[idx++], uint8_t, value ? 0xff : 0x00, int); + H5_CHECKED_ASSIGN(buf[idx++], uint8_t, value ? 0xff : 0x00, int); size -= 8; } @@ -532,7 +532,7 @@ H5T__bit_inc(uint8_t *buf, size_t start, size_t size) acc = buf[idx]; acc++; carry = acc & 0x100; - ASSIGN_TO_SMALLER_SIZE(buf[idx], uint8_t, acc & 0xff, unsigned); + H5_CHECKED_ASSIGN(buf[idx], uint8_t, acc & 0xff, unsigned); idx++; size -= 8; } |