Merge pull request #1817 from noahmetzger/winfix

Fix issue detected by Coverity Scan
This commit is contained in:
zdenop 2018-08-01 16:55:56 +02:00 committed by GitHub
commit d22ca6bb06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -926,7 +926,8 @@ void ColumnFinder::ComputeMeanColumnGap(bool any_multi_column) {
&gap_samples);
}
mean_column_gap_ = any_multi_column && gap_samples > 0
? total_gap / gap_samples : total_width / width_samples;
? total_gap / gap_samples : width_samples > 0
? total_width / width_samples : 0;
}
//////// Functions that manipulate ColPartitions in the part_grid_ /////