C++: Remove FPs from cpp/badly-bounded-write

This commit is contained in:
Calum Grant
2024-12-05 14:37:19 +00:00
parent fd7469848e
commit b7f47f752b
2 changed files with 2 additions and 2 deletions

View File

@@ -25,7 +25,8 @@ from BufferWrite bw, int destSize
where
bw.hasExplicitLimit() and // has an explicit size limit
destSize = max(getBufferSize(bw.getDest(), _)) and
bw.getExplicitLimit() > destSize // but it's larger than the destination
bw.getExplicitLimit() > destSize and // but it's larger than the destination
not bw.getDest().getUnderlyingType().stripType() instanceof ErroneousType // destSize may be incorrect
select bw,
"This '" + bw.getBWDesc() + "' operation is limited to " + bw.getExplicitLimit() +
" bytes but the destination is only " + destSize + " bytes."