0af193c Ticket #305 - Certain CMP operations hang or cause ns-slapd to crash

Authored and Committed by rmeggins 7 years ago
    Ticket #305 - Certain CMP operations hang or cause ns-slapd to crash
    
    https://fedorahosted.org/389/ticket/305
    Resolves: Ticket #305
    Bug Description: Certain CMP operations hang or cause ns-slapd to crash
    Reviewed by: nkinder, nhosoi (Thanks!)
    Branch: rhel-6.3
    Fix Description: This addresses the hang part, which I incorrectly assumed
    was related to the crash part.  The code using vattr_map_sp_next() was causing
    an infinite loop (and hang) by passing the list head every time rather than
    the previous next pointer.
    In addition, LDAP compare operations were not working if a vattr service
    provider was in effect for an attribute, and there was a real value for
    the attribute in the entry.  The rc code was being set to -1 to indicate
    no vattr service providers provided the value, but it was not being reset
    to 0 when the value was found in the actual entry.  The fix is to reset
    rc to 0 (success) and *result to 0 (compare false) when testing the real
    attribute.
    Platforms tested: RHEL6 x86_64
    Flag Day: no
    Doc impact: no
    (cherry picked from commit 55135e37a9e330f084ab7d254306cbf155526b25)
    (cherry picked from commit f00c678e36c138a7991b6c3c4780d40af30dc7c4)
    
        
file modified
+4 -2