diff options
Diffstat (limited to 'src/backend/commands')
-rw-r--r-- | src/backend/commands/indexcmds.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/backend/commands/indexcmds.c b/src/backend/commands/indexcmds.c index 412e1ba84f4..4ee498d9855 100644 --- a/src/backend/commands/indexcmds.c +++ b/src/backend/commands/indexcmds.c @@ -3347,6 +3347,8 @@ ReindexMultipleInternal(const ReindexStmt *stmt, const List *relids, const Reind newparams.options |= REINDEXOPT_MISSING_OK; (void) ReindexRelationConcurrently(stmt, relid, &newparams); + if (ActiveSnapshotSet()) + PopActiveSnapshot(); /* ReindexRelationConcurrently() does the verbose output */ } else if (relkind == RELKIND_INDEX) @@ -3698,10 +3700,7 @@ ReindexRelationConcurrently(const ReindexStmt *stmt, Oid relationOid, const Rein * session until this operation completes. */ if (indexIds == NIL) - { - PopActiveSnapshot(); return false; - } /* It's not a shared catalog, so refuse to move it to shared tablespace */ if (params->tablespaceOid == GLOBALTABLESPACE_OID) |