Skip to content

Commit

Permalink
cwe-mapper: suppres a false positive of Coverity
Browse files Browse the repository at this point in the history
```
Error: PASS_BY_VALUE (CWE-398):
src/lib/cwe-mapper.cc:38:45: pass_by_value: Passing parameter def of type "Defect" (size 200 bytes) by value, which exceeds the low threshold of 128 bytes.
```

Closes: #216
  • Loading branch information
kdudka committed Dec 12, 2024
1 parent ba468e9 commit a61fae3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lib/cwe-mapper.cc
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ struct CweMap::Private {
bool detectedByTool(Defect def, const char *tool) const;
};

// coverity[pass_by_value]
bool CweMap::Private::detectedByTool(Defect def, const char *tool) const
{
// detect tool in case it is not explicitly specified
Expand Down

0 comments on commit a61fae3

Please sign in to comment.