add missing const
If you want to declare a pointer which the address pointed to is constant, you should declare it as like `static const char *const var = "...";`. This commit supplies missing `const` and prevents some programming error in the future.
This commit is contained in:
@@ -461,7 +461,7 @@ DISABLE_WARNING_FORMAT_NONLITERAL
|
||||
void
|
||||
readmail(struct obj *otmp UNUSED)
|
||||
{
|
||||
static const char *junk[] = {
|
||||
static const char *const junk[] = {
|
||||
"Report bugs to <%s>.", /*** must be first entry ***/
|
||||
"Please disregard previous letter.",
|
||||
"Welcome to NetHack.",
|
||||
|
||||
Reference in New Issue
Block a user