VariantDraft
CWE-482Comparing instead of Assigning
Category: other
Description
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.
Common consequences· 1
- Availability / Integrity — Unexpected StateThe assignment will not take place, which should cause obvious program execution problems.
Potential mitigations· 1
- [Testing]Many IDEs and static analysis products will detect this problem.
References
(incoming)1
| Type | Target | Confidence | Tier |
|---|---|---|---|
| Vulnerability | CVE-2026-26279cve-2026-26279 | 0% | live |
Related by meaning· 6
Nearest entities by semantic similarity across the cs-graph corpus.