Ensure that a cursor has an immutable snapshot throughout its lifespan.

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

Commit: ae35363dced47a99178b4a4129e3ea1f990b829c
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
Date: 2009-10-02T17:58:21Z
Releases: 8.4.2
Ensure that a cursor has an immutable snapshot throughout its lifespan.

The old coding was using a regular snapshot, referenced elsewhere, that was
subject to having its command counter updated.  Fix by creating a private copy
of the snapshot exclusively for the cursor.

Backpatch to 8.4, which is when the bug was introduced during the snapshot
management rewrite.

Files