diff options
author | Ryan Moeller <[email protected]> | 2020-10-02 20:44:10 -0400 |
---|---|---|
committer | GitHub <[email protected]> | 2020-10-02 17:44:10 -0700 |
commit | 4d55ea811d4f5b832398f4e3b24c4da365956d62 (patch) | |
tree | c799540f0984809efa47a3b5d2218940def15297 /module/unicode/u8_textprep.c | |
parent | 5b525165e9113e7faabd230b504ae4e9b85d35a5 (diff) |
Throw const on some strings
In C, const indicates to the reader that mutation will not occur.
It can also serve as a hint about ownership.
Add const in a few places where it makes sense.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Ryan Moeller <[email protected]>
Closes #10997
Diffstat (limited to 'module/unicode/u8_textprep.c')
-rw-r--r-- | module/unicode/u8_textprep.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/module/unicode/u8_textprep.c b/module/unicode/u8_textprep.c index 65f555d88..be816d728 100644 --- a/module/unicode/u8_textprep.c +++ b/module/unicode/u8_textprep.c @@ -330,7 +330,7 @@ const uint8_t u8_valid_max_2nd_byte[0x100] = { * specific to UTF-8 and Unicode. */ int -u8_validate(char *u8str, size_t n, char **list, int flag, int *errnum) +u8_validate(const char *u8str, size_t n, char **list, int flag, int *errnum) { uchar_t *ib; uchar_t *ibtail; |