Don't try to use a unopened relation

Alvaro Herrera <alvherre@alvh.no-ip.org>

Commit: 4ee5c40b06f098910ed0fc5fd72fb2744776ccbb
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
Date: 2012-11-07T19:23:39Z
Releases: 9.3.0
Don't try to use a unopened relation

Commit 4c9d0901 mistakenly introduced a call to
TransferPredicateLocksToHeapRelation() on an index relation that had
been closed a few lines above.  Moving up an index_open() call that's
below is enough to fix the problem.

Discovered by me while testing an unrelated patch.

Files

PathChange+/−
src/backend/catalog/index.c modified +2 −3