ldb: avoid NULL deref in ldb_db_compare
commitaf7654331fb6a2d9cc41cf5bdffa74c81ff4ffee
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Fri, 26 Apr 2024 03:24:47 +0000 (26 15:24 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Tue, 7 May 2024 23:25:35 +0000 (7 23:25 +0000)
tree98a4e1be8dba1f7be1f6b5d18bc233d03269615d
parentd58a72c572f63619111f43f6ea39ff84ae0df16e
ldb: avoid NULL deref in ldb_db_compare

This also sorts NULLs after invalid DNs, which matches the comment
above.

CID 1596622.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=15625

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
lib/ldb/common/ldb_dn.c