diff options
author | Pavel Reichl <preichl@redhat.com> | 2014-05-27 19:11:20 +0100 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2014-06-25 16:03:51 +0200 |
commit | 5153e8b9793dea1e212ca08af0f77ea1d023cbb7 (patch) | |
tree | d521872a8153e8a548c995448dc033efa32b5967 /src/db/sysdb.h | |
parent | a47cb2e08e4004179d2a6b5f9a9340200270fbd0 (diff) | |
download | sssd-5153e8b9793dea1e212ca08af0f77ea1d023cbb7.tar.gz sssd-5153e8b9793dea1e212ca08af0f77ea1d023cbb7.tar.xz sssd-5153e8b9793dea1e212ca08af0f77ea1d023cbb7.zip |
SYSDB: sss_ldb_search - wrapper around ldb_search
Make sure that if no results were found ENOENT is returned rather than just
empty list of results.
Resolves:
https://fedorahosted.org/sssd/ticket/1991
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com>
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
Diffstat (limited to 'src/db/sysdb.h')
-rw-r--r-- | src/db/sysdb.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/db/sysdb.h b/src/db/sysdb.h index 911430eef..17cd5110c 100644 --- a/src/db/sysdb.h +++ b/src/db/sysdb.h @@ -481,6 +481,11 @@ int sysdb_get_netgroup_attr(TALLOC_CTX *mem_ctx, const char **attributes, struct ldb_result **res); +errno_t sss_ldb_search(struct ldb_context *ldb, TALLOC_CTX *mem_ctx, + struct ldb_result **_result, struct ldb_dn *base, + enum ldb_scope scope, const char * const *attrs, + const char *exp_fmt, ...) SSS_ATTRIBUTE_PRINTF(7, 8); + /* functions that modify the databse * they have to be called within a transaction * See sysdb_transaction_send()/_recv() */ |