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:
@@ -37,7 +37,7 @@ static const char *
|
||||
lock_action(void)
|
||||
{
|
||||
/* "unlocking"+2 == "locking" */
|
||||
static const char *actions[] = {
|
||||
static const char *const actions[] = {
|
||||
"unlocking the door", /* [0] */
|
||||
"unlocking the chest", /* [1] */
|
||||
"unlocking the box", /* [2] */
|
||||
|
||||
Reference in New Issue
Block a user