...
| Code Block | ||
|---|---|---|
| ||
enum { IN_STR_LEN=18, OUT_STR_LEN=20 };
|
Consequently, a A programmer performing maintenance on this program would need to identify the relationship and modify both definitions accordingly. While this sort of error appears relatively benign, it can easily lead to serious security vulnerabilities such as buffer overflows.
...
| Code Block | ||
|---|---|---|
| ||
enum { ADULT_AGE=18 };
/* misleading, relationship established when none exists */
enum { ALCOHOL_AGE=ADULT_AGE+3 };
|
Consequently, a A programmer performing maintenance on this program may modify the definition for ADULT_AGE but fail to recognize that the definition for ALCOHOL_AGE has also been changed as a consequence.
...