On 9/15/17 08:43, Thomas Munro wrote:
> On Fri, Sep 15, 2017 at 2:12 AM, Alvaro Herrera <alvhe...@alvh.no-ip.org> 
> wrote:
>> I think the ldap_unbind() changes should be in a separate preliminary
>> patch to be committed separately and backpatched.
> 
> OK, here it is split into two patches.

I've looked this over.

In the 0001 patch, I would move the ldap_unbind() calls after the
ereport(LOG) calls.  We do all the other resource cleanup (pfree() etc.)
after the ereport() calls, so it would be weird to do this one
differently.  Also, in the second patch you move one of the
ldap_unbind() calls down anyway.

In the 0002 patch, I think this is a bit repetitive and could be
refactored even more.  The end result could look like

    ereport(LOG,
            (errmsg("blah"),
             errdetail_for_ldap(ldap)));
    ldap_unbind(ldap);

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to