Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
const int vals[] = {3, 4, 5};
memset((int *)vals, 0, sizeof(vals));

Compliant

...

Solution

If the intention is to allow the array values to be modified, do not declare the array as const.

...