Re: [HACKERS] Group clear xid can leak semaphore count

2017-01-05 Thread Amit Kapila
On Fri, Jan 6, 2017 at 1:13 AM, Robert Haas wrote: > On Sat, Dec 31, 2016 at 12:44 AM, Amit Kapila wrote: >> During the review of Group update Clog patch [1], Dilip noticed an >> issue with the patch where it can leak the semaphore count in one of

Re: [HACKERS] Group clear xid can leak semaphore count

2017-01-05 Thread Robert Haas
On Thu, Jan 5, 2017 at 4:48 PM, Tom Lane wrote: > Robert Haas writes: >> I think we have run into this kind of issue before. I wonder if >> there's any way to insert some kind of a guard - e.g. detect at >> backend startup time that the semaphore has a

Re: [HACKERS] Group clear xid can leak semaphore count

2017-01-05 Thread Tom Lane
Robert Haas writes: > I think we have run into this kind of issue before. I wonder if > there's any way to insert some kind of a guard - e.g. detect at > backend startup time that the semaphore has a non-zero value and fix > it, issuing a warning along the way... maybe

Re: [HACKERS] Group clear xid can leak semaphore count

2017-01-05 Thread Robert Haas
On Sat, Dec 31, 2016 at 12:44 AM, Amit Kapila wrote: > During the review of Group update Clog patch [1], Dilip noticed an > issue with the patch where it can leak the semaphore count in one of > the corner case. I have checked and found that similar issue exists > for