CWE-482—Comparing instead of Assigning
PUBLISHEDweakness recordLow
released 2006-07-19 · last modified 2026-04-30
Metadata
名称
Comparing instead of Assigning
描述
The code uses an operator for comparison when the intention was to perform an assignment.
In many languages, the compare statement is very close in appearance to the assignment statement; they are often confused.