Description
For error handling on analyzeRelation failure in analyzeStmt,
RollbackAndReleaseCurrentSubTransaction would be called and finally
result in AtEOSubXact_SPI for resource release.
However, the sub-transaction ID of the ANALYZE statement does not match
that of the original SPI invoke. And this would result in an early
release of the SPI's memory context, leading to memory corruption when
there is still any other queries following the ANALYZE statement.