diff --git a/source/adios2/core/adios2_libinfo.cpp b/source/adios2/core/adios2_libinfo.cpp index 31da7a2fc0..b36a2349e3 100644 --- a/source/adios2/core/adios2_libinfo.cpp +++ b/source/adios2/core/adios2_libinfo.cpp @@ -57,7 +57,7 @@ static const char *aae[] = {"BP3", "Skeleton", nullptr}; -void adios2_available_engines(int *nentries, char const ***list) +void adios2_available_engines(int *nentries, char const *const **list) { int ne = 0; while (aae[ne] != nullptr) @@ -99,7 +99,7 @@ static const char *aao[] = { "None", nullptr}; -void adios2_available_operators(int *nentries, char const ***list) +void adios2_available_operators(int *nentries, char const *const **list) { int no = 0; while (aao[no] != nullptr) @@ -148,7 +148,7 @@ static const char *aaf[] = { #endif nullptr}; -void adios2_available_features(int *nentries, char const ***list) +void adios2_available_features(int *nentries, char const *const **list) { int nf = 0; while (aaf[nf] != nullptr) @@ -158,8 +158,6 @@ void adios2_available_features(int *nentries, char const ***list) return; } -void adios2_free_list(int nentries, char const ***list) {} - #ifdef __cplusplus } // end extern C #endif diff --git a/source/adios2/core/adios2_libinfo.h b/source/adios2/core/adios2_libinfo.h index 29a6645616..662f43334d 100644 --- a/source/adios2/core/adios2_libinfo.h +++ b/source/adios2/core/adios2_libinfo.h @@ -21,18 +21,13 @@ extern const int adios2_version_patch; extern const char *const adios2_version_str; /** Return the list of available Engines in the installed adios2 library */ -void adios2_available_engines(int *nentries, char const ***list); +void adios2_available_engines(int *nentries, char const *const **list); /** Return the list of available Engines in the installed adios2 library */ -void adios2_available_operators(int *nentries, char const ***list); +void adios2_available_operators(int *nentries, char const *const **list); /** Return the list of available features in the installed adios2 library */ -void adios2_available_features(int *nentries, char const ***list); - -/** Free function for list returned by adios2_available_engines() and - * adios2_available_operators() - */ -void adios2_free_list(int nentries, char const ***list); +void adios2_available_features(int *nentries, char const *const **list); #ifdef __cplusplus } // end extern C diff --git a/source/utils/bpls/bpls.cpp b/source/utils/bpls/bpls.cpp index 1f8d60d1fd..33b56eeaea 100644 --- a/source/utils/bpls/bpls.cpp +++ b/source/utils/bpls/bpls.cpp @@ -252,7 +252,7 @@ void print_bpls_version() printf("Target Arch: %s\n", ADIOS_INFO_ARCH); int nengines; - char const **list_engines; + char const *const *list_engines; adios2_available_engines(&nengines, &list_engines); printf("Available engines = %d:", nengines); for (int i = 0; i < nengines; ++i) @@ -264,10 +264,9 @@ void print_bpls_version() } } printf("\n"); - adios2_free_list(nengines, &list_engines); int noperators; - char const **list_operators; + char const *const *list_operators; adios2_available_operators(&noperators, &list_operators); printf("Available operators = %d:", noperators); for (int i = 0; i < noperators; ++i) @@ -279,10 +278,9 @@ void print_bpls_version() } } printf("\n"); - adios2_free_list(noperators, &list_operators); int nfeatures; - char const **list_features; + char const *const *list_features; adios2_available_features(&nfeatures, &list_features); printf("Available features = %d:", nfeatures); for (int i = 0; i < nfeatures; ++i) @@ -294,7 +292,6 @@ void print_bpls_version() } } printf("\n"); - adios2_free_list(nfeatures, &list_features); } }