]> git.ipfire.org Git - thirdparty/samba.git/commit
pyldb: Improve search for error string in PyErr_SetLdbError
authorAndrew Bartlett <abartlet@samba.org>
Sun, 24 Mar 2024 23:44:29 +0000 (12:44 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 28 Mar 2024 01:50:41 +0000 (01:50 +0000)
commit565314f448236ff41d9c6c532949c19ee85b6425
treeae859ba9da5ad9dbdff17532b3d9ecd6384cdbb0
parent06912de3b2ae84c795f5d3e7ee03872937260ee4
pyldb: Improve search for error string in PyErr_SetLdbError

We allow a fallback to ldb_strerror() even if there was an LDB context,
allowing failing functions to reset a previous error string but not
set a new one.

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