mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Annotate source code to please coverity
This code is signalled as a copy and paste error, but it is a false positive. According to the documentation, adding a comment starting with // coverity[name_of_error] should be enough to flag the false positive.
This commit is contained in:
parent
5e5440f2f3
commit
731dbddd11
@ -481,6 +481,11 @@ bool TextMetrics::redoParagraph(pit_type const pit)
|
|||||||
if (text_->isMainText()) {
|
if (text_->isMainText()) {
|
||||||
if (pit == 0) {
|
if (pit == 0) {
|
||||||
pm.rows().front().dimension().asc += 20;
|
pm.rows().front().dimension().asc += 20;
|
||||||
|
/* coverity[copy_paste_error]: coverity thinks that we
|
||||||
|
* should update pm.dim().asc below, but all the rows
|
||||||
|
* heights are actually counted as part of the paragraph metric
|
||||||
|
* descent see loop above).
|
||||||
|
*/
|
||||||
pm.dim().des += 20;
|
pm.dim().des += 20;
|
||||||
}
|
}
|
||||||
ParagraphList const & pars = text_->paragraphs();
|
ParagraphList const & pars = text_->paragraphs();
|
||||||
|
Loading…
Reference in New Issue
Block a user