adamwill / 389-ds-base

Forked from 389-ds-base 4 years ago
Clone

666fdac Ticket: 48341 - deadlock on connection mutex

1 file Authored by lkrispen 8 years ago, Committed by nhosoi 8 years ago,
    Ticket: 48341 - deadlock on connection mutex
    
    If  thread is blocked in connection_read_operation() it holds the connection mutex
    and the main thread iterating through the connection table is also blocked.
    
    But if the main thread would get the mutex it would just detect that the connection has still the
    C_gettingber flag set and immediately release the lock.
    
    The check if c_gettingber == 0 can be done without holding the mutex and so the deadlock
    can be avoided
    
    Reviewed by Rich, Thanks
    
    (cherry picked from commit a1635fc45f681ed9066f6beed9be7e1672490f9f)
    
        
file modified
+3 -0