Re: Avoid resource leak (src/test/modules/test_binaryheap/test_binaryheap.c)

2025-09-12 Thread Tom Lane
Robert Haas writes: > On Fri, Sep 12, 2025 at 1:54 PM Ranier Vilela wrote: >> Coverity reports this resource leak in test_binaryheap module. >> I think that is right. > If this were correct, we'd need to also free the memory in all the > error paths. But of course, in both error and non-error pa

Re: Avoid resource leak (src/test/modules/test_binaryheap/test_binaryheap.c)

2025-09-12 Thread Robert Haas
On Fri, Sep 12, 2025 at 1:54 PM Ranier Vilela wrote: > Per Coverity. > > Coverity reports this resource leak in test_binaryheap module. > I think that is right. > > Trivial patch attached. If this were correct, we'd need to also free the memory in all the error paths. But of course, in both error