Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 5871f09

Browse files
committed
Fix autovacuum cancellation.
The problem is caused by me (Andres) having ProcSleep() look at the wrong PGPROC entry in 5788e25. Unfortunately it seems hard to write a reliable test for autovacuum cancellations. Perhaps somebody will come up with a good approach, but it seems worth fixing the issue even without a test. Reported-By: Jeff Janes <jeff.janes@gmail.com> Author: Jeff Janes <jeff.janes@gmail.com> Discussion: https://postgr.es/m/CAMkU=1wH2aUy+wDRDz+5RZALdcUnEofV1t9PzXS_gBJO9vZZ0Q@mail.gmail.com
1 parent 3438c98 commit 5871f09

File tree

1 file changed

+1
-1
lines changed
  • src/backend/storage/lmgr

1 file changed

+1
-1
lines changed

src/backend/storage/lmgr/proc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1318,7 +1318,7 @@ ProcSleep(LOCALLOCK *locallock, LockMethod lockMethodTable)
13181318
* Only do it if the worker is not working to protect against Xid
13191319
* wraparound.
13201320
*/
1321-
vacuumFlags = ProcGlobal->vacuumFlags[proc->pgxactoff];
1321+
vacuumFlags = ProcGlobal->vacuumFlags[autovac->pgxactoff];
13221322
if ((vacuumFlags & PROC_IS_AUTOVACUUM) &&
13231323
!(vacuumFlags & PROC_VACUUM_FOR_WRAPAROUND))
13241324
{

0 commit comments

Comments
 (0)