diff options
author | Noah Misch <noah@leadboat.com> | 2024-11-02 19:42:52 -0700 |
---|---|---|
committer | Noah Misch <noah@leadboat.com> | 2024-11-02 19:42:56 -0700 |
commit | f8f9110b4d33821ccb3e67454b3799448e2a325f (patch) | |
tree | 2e253227661807d8d0e45962f050584f3e3cb96d /src | |
parent | 6c837c237bf821ee78522259c847f417d1e11fd7 (diff) | |
download | postgresql-f8f9110b4d33821ccb3e67454b3799448e2a325f.tar.gz postgresql-f8f9110b4d33821ccb3e67454b3799448e2a325f.zip |
Suppress new "may be used uninitialized" warning.
Buildfarm member mamba fails to deduce that the function never uses this
variable without initializing it. Back-patch to v12, like commit
b412f402d1e020c5dac94f3bf4a005db69519b99.
Diffstat (limited to 'src')
-rw-r--r-- | src/backend/catalog/index.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/backend/catalog/index.c b/src/backend/catalog/index.c index 7b8c8ba2561..bc08ab66bd6 100644 --- a/src/backend/catalog/index.c +++ b/src/backend/catalog/index.c @@ -2813,8 +2813,8 @@ index_update_stats(Relation rel, double reltuples) { bool update_stats; - BlockNumber relpages; - BlockNumber relallvisible; + BlockNumber relpages = 0; /* keep compiler quiet */ + BlockNumber relallvisible = 0; Oid relid = RelationGetRelid(rel); Relation pg_class; ScanKeyData key[1]; @@ -2851,8 +2851,6 @@ index_update_stats(Relation rel, if (rel->rd_rel->relkind != RELKIND_INDEX) visibilitymap_count(rel, &relallvisible, NULL); - else /* don't bother for indexes */ - relallvisible = 0; } /* |