mirror of
https://github.com/postgres/postgres.git
synced 2025-11-09 06:21:09 +03:00
Remove superfluous 'pgprocno' field from PGPROC
It was always just the index of the PGPROC entry from the beginning of the proc array. Introduce a macro to compute it from the pointer instead. Reviewed-by: Andres Freund Discussion: https://www.postgresql.org/message-id/8171f1aa-496f-46a6-afc3-c46fe7a9b407@iki.fi
This commit is contained in:
@@ -248,7 +248,7 @@ WalSummarizerMain(void)
|
||||
/* Advertise ourselves. */
|
||||
on_shmem_exit(WalSummarizerShutdown, (Datum) 0);
|
||||
LWLockAcquire(WALSummarizerLock, LW_EXCLUSIVE);
|
||||
WalSummarizerCtl->summarizer_pgprocno = MyProc->pgprocno;
|
||||
WalSummarizerCtl->summarizer_pgprocno = MyProcNumber;
|
||||
LWLockRelease(WALSummarizerLock);
|
||||
|
||||
/* Create and switch to a memory context that we can reset on error. */
|
||||
|
||||
Reference in New Issue
Block a user