!2758 函数estimatePartitionSize内部变量curpages判断条件不准确

Merge pull request !2758 from foolishlee/estimatePartitionSize
This commit is contained in:
opengauss-bot
2023-01-18 03:13:33 +00:00
committed by Gitee

View File

@ -1971,7 +1971,7 @@ void estimatePartitionSize(
* pages added since the last VACUUM are most likely not marked
* all-visible. But costsize.c wants it converted to a fraction.
*/
if (partitionallvisible == 0 || curpages <= 0) {
if (partitionallvisible == 0 || curpages == 0) {
*allvisfrac = 0;
} else if ((double)partitionallvisible >= curpages) {
*allvisfrac = 1;