prevent-setval-during-recovery.patch
text/x-patch
Filename: prevent-setval-during-recovery.patch
Type: text/x-patch
Part: 0
Patch
Same data as JSON:
GET /api/v1/attachments/:id/patch
the parsed metadata as JSON — format, series position, per-file stats; never the diff bytes.
API reference →
Format: unified
| File | + | − |
|---|---|---|
| src/backend/commands/sequence.c | 0 | 0 |
diff --git a/src/backend/commands/sequence.c b/src/backend/commands/sequence.c index 0f9dcfe..d696203 100644 *** a/src/backend/commands/sequence.c --- b/src/backend/commands/sequence.c *************** do_setval(Oid relid, int64 next, bool is *** 738,743 **** --- 738,746 ---- Buffer buf; Form_pg_sequence seq; + /* setval() writes to database and must be prevented during recovery */ + PreventCommandDuringRecovery(); + /* open and AccessShareLock sequence */ init_sequence(relid, &elm, &seqrel);