Hi Li-san Thank you for sharing this fix patch.
>BackendPidGetProc() returns a PGPROC pointer after releasing >ProcArrayLock, so the returned PGPROC is no longer protected. The ? >corresponding entry in allProcs could be recycled after the function >returns, in which case proc could refer to a different process when proc- >>databaseId is accessed. I'm not sure how long the PGPROC might be reused or modified after it is retrieved, but it's true that the scenario you're describing could occur depending on the timing. I think this fix looks good. I would appreciate hearing what the other members think. Regards, Aya Iwata
