Skip to content

Commit

Permalink
snis_client: remove some bogus const type qualifiers on function retu…
Browse files Browse the repository at this point in the history
…rn types

Signed-off-by: Stephen M. Cameron <[email protected]>
  • Loading branch information
smcameron committed Dec 28, 2021
1 parent 5ae7791 commit b89bf3a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion commodities.c
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ const char *commodity_category_description(int cat)
return category_description[cat];
}

const int ncommodity_categories(void)
int ncommodity_categories(void)
{
return ncategories;
}
Expand Down
2 changes: 1 addition & 1 deletion commodities.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,6 @@ int lookup_commodity(struct commodity *c, int ncommodities, const char *commodit

const char *commodity_category(int cat);
const char *commodity_category_description(int cat);
const int ncommodity_categories(void);
int ncommodity_categories(void);

#endif
4 changes: 2 additions & 2 deletions snis_opcode_def.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ static void check_index(int index)
}

/* Returns payload size of an opcode (that has no subcode) */
const int snis_opcode_payload_size(uint8_t opcode)
int snis_opcode_payload_size(uint8_t opcode)
{
int index = opcode * NSUBCODES;

Expand All @@ -311,7 +311,7 @@ const int snis_opcode_payload_size(uint8_t opcode)
}

/* Returns payload size of an opcode, subcode pair */
const int snis_opcode_subcode_payload_size(uint8_t opcode, uint8_t subcode)
int snis_opcode_subcode_payload_size(uint8_t opcode, uint8_t subcode)
{
int index = opcode * NSUBCODES + subcode;

Expand Down
4 changes: 2 additions & 2 deletions snis_opcode_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@
int snis_opcode_def_init(void);

/* Returns payload size of an opcode (that has no subcode) */
const int snis_opcode_payload_size(uint8_t opcode);
int snis_opcode_payload_size(uint8_t opcode);
/* Returns payload size of an opcode, subcode pair */
const int snis_opcode_subcode_payload_size(uint8_t opcode, uint8_t subcode);
int snis_opcode_subcode_payload_size(uint8_t opcode, uint8_t subcode);
/* Returns format of opcode that has no subcode */
const char *snis_opcode_format(uint8_t opcode);
/* Returns format of an opcode, subcode pair */
Expand Down

0 comments on commit b89bf3a

Please sign in to comment.