Const correctness (To aid migration to C++)

This commit is contained in:
Shahram Najm 2022-06-30 10:29:46 +01:00
parent 2be3dddd15
commit 766f4aeb63
2 changed files with 4 additions and 4 deletions

View File

@ -402,7 +402,7 @@ int grib_process_runtime_options(grib_context* context, int argc, char** argv, g
return GRIB_SUCCESS;
}
char* grib_options_get_help(char* id)
const char* grib_options_get_help(const char* id)
{
int i = 0;
char msg[] = "ERROR: help not found for option ";
@ -424,7 +424,7 @@ char* grib_options_get_help(char* id)
return err;
}
char* grib_options_get_args(char* id)
const char* grib_options_get_args(const char* id)
{
int i = 0;
char empty[] = "";

View File

@ -189,8 +189,8 @@ int grib_options_on(const char* id);
int grib_options_get(int argc, char** argv);
int grib_options_get_values(int argc, char** argv, int values_required, int default_type, grib_values values[], int* n, int* optind);
int grib_tool(int argc, char** argv);
char* grib_options_get_help(char* id);
char* grib_options_get_args(char* id);
const char* grib_options_get_help(const char* id);
const char* grib_options_get_args(const char* id);
int grib_options_command_line(const char* id);
void usage(void);
void usage_doxygen(void);