1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-09 13:09:39 +03:00

Make DISCARD SEQUENCES also discard the last used sequence.

Otherwise, we access already-freed memory.  Oops.

Report by Michael Paquier.  Fix by me.
This commit is contained in:
Robert Haas
2013-10-07 15:55:56 -04:00
parent 689746c045
commit 16a906f535
3 changed files with 7 additions and 0 deletions

View File

@@ -1617,4 +1617,6 @@ ResetSequenceCaches(void)
free(seqtab);
seqtab = next;
}
last_used_seq = NULL;
}