Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ldb_ldap: fix off-by-one increment in lldb_add_msg_attr
Fix regression introduced by commit ce2bf5c lldb_add_msg_attr() calls ldb_msg_add_empty() which, in turn, calls calls _ldb_msg_add_el() which already increments msg->num_elements by one. As a result, msg->num_elements is bigger than the actual number of elements and any iteration over elements would step over elements array boundary. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14413 Signed-off-by: Alexander Bokovoy <[email protected]> Reviewed-by: Andreas Schneider <[email protected]> Autobuild-User(master): Andreas Schneider <[email protected]> Autobuild-Date(master): Fri Jun 19 08:35:33 UTC 2020 on sn-devel-184
- Loading branch information