f4fddaf LDAP: do not invalidate pointer with realloc while processing ghost users

Authored and Committed by jhrozek 8 years ago
    LDAP: do not invalidate pointer with realloc while processing ghost users
    
    https://fedorahosted.org/sssd/ticket/1799
    
    One peculiarity of the sysdb_attrs_get_el interface is that if the
    attribute does not exist, then the attrs array is reallocated and the
    element is created. But in case other pointers are already pointing
    into the array, the realloc might invalidate them.
    
    Such case was in the sdap_process_ghost_members function where if
    the group had no members, the "gh" pointer requested earlier might have
    been invalidated by the realloc in order to create the member element.