1
0
mirror of https://github.com/TREX-CoE/trexio.git synced 2024-11-03 20:54:07 +01:00

Fixed style: Use pointers to const when referring to string literals [cert-STR05-C]

This commit is contained in:
Anthony Scemama 2023-03-24 12:16:57 +01:00
parent 7c8bcef271
commit 42592c4454

View File

@ -694,7 +694,7 @@ trexio_exit_code trexio_hdf5_read_$group_dset$(trexio_t* const file,
if (eof_read_size == NULL) return TREXIO_INVALID_ARG_5;
if (dset == NULL) return TREXIO_INVALID_ARG_6;
const char dset_name[256] = "$group_dset$";
const char* dset_name = "$group_dset$";
const trexio_hdf5_t* f = (const trexio_hdf5_t*) file;
@ -718,7 +718,7 @@ trexio_exit_code trexio_hdf5_write_$group_dset$(trexio_t* const file,
if (file == NULL) return TREXIO_INVALID_ARG_1;
if (dset == NULL) return TREXIO_INVALID_ARG_5;
const char dset_name[256] = "$group_dset$";
const char* dset_name = "$group_dset$";
trexio_hdf5_t* f = (trexio_hdf5_t*) file;
@ -756,7 +756,7 @@ trexio_hdf5_read_$group_dset$_size (trexio_t* const file, int64_t* const size_ma
if (file == NULL) return TREXIO_INVALID_ARG_1;
if (size_max == NULL) return TREXIO_INVALID_ARG_2;
const char dset_name[256] = "$group_dset$";
const char* dset_name = "$group_dset$";
const trexio_hdf5_t* f = (const trexio_hdf5_t*) file;
@ -792,7 +792,7 @@ trexio_exit_code trexio_hdf5_has_$group_dset$(trexio_t* const file)
trexio_hdf5_t* f = (trexio_hdf5_t*) file;
if (f->$group$_group == (hsize_t) 0) return TREXIO_HAS_NOT;
const char dset_name[256] = "$group_dset$";
const char* dset_name = "$group_dset$";
htri_t exists = H5Lexists(f->$group$_group, dset_name, H5P_DEFAULT);
if (exists > 0) {