diff options
author | Sumit Bose <sbose@redhat.com> | 2012-02-03 13:57:00 +0100 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2012-02-29 12:53:47 -0500 |
commit | b7b50b21d2254a079b1b1c299909483d23db1512 (patch) | |
tree | c2c9b2bff77dfadb9d70d348ad6ffb06c60e8d2b /src/db | |
parent | d2d2d6ae0c436461bcc8f881df059eb036314c44 (diff) | |
download | sssd-b7b50b21d2254a079b1b1c299909483d23db1512.tar.gz sssd-b7b50b21d2254a079b1b1c299909483d23db1512.tar.xz sssd-b7b50b21d2254a079b1b1c299909483d23db1512.zip |
Remove sysdb_get_ctx_from_list()
Diffstat (limited to 'src/db')
-rw-r--r-- | src/db/sysdb.c | 29 | ||||
-rw-r--r-- | src/db/sysdb.h | 4 |
2 files changed, 0 insertions, 33 deletions
diff --git a/src/db/sysdb.c b/src/db/sysdb.c index d3a20cf1e..bec250570 100644 --- a/src/db/sysdb.c +++ b/src/db/sysdb.c @@ -1310,35 +1310,6 @@ fail: return ret; } -int sysdb_get_ctx_from_list(struct sysdb_ctx_list *ctx_list, - struct sss_domain_info *domain, - struct sysdb_ctx **sysdb) -{ - int i; - - if (domain->sysdb != NULL) { - *sysdb = domain->sysdb; - return EOK; - } - - DEBUG(SSSDBG_TRACE_FUNC, ("sysdb context not stored in domain, " - "trying to find by name.\n")); - - for (i = 0; i < ctx_list->num_dbs; i++) { - if (ctx_list->dbs[i]->domain == domain) { - *sysdb = ctx_list->dbs[i]; - return EOK; - } - if (strcasecmp(ctx_list->dbs[i]->domain->name, domain->name) == 0) { - *sysdb = ctx_list->dbs[i]; - return EOK; - } - } - /* definitely not found */ - return ENOENT; -} - - int compare_ldb_dn_comp_num(const void *m1, const void *m2) { struct ldb_message *msg1 = talloc_get_type(*(void **) discard_const(m1), diff --git a/src/db/sysdb.h b/src/db/sysdb.h index 1da61f2c1..5cec84844 100644 --- a/src/db/sysdb.h +++ b/src/db/sysdb.h @@ -340,10 +340,6 @@ int sysdb_list_init(TALLOC_CTX *mem_ctx, struct sysdb_ctx *sysdb, struct sysdb_ctx_list **_list); -int sysdb_get_ctx_from_list(struct sysdb_ctx_list *ctx_list, - struct sss_domain_info *domain, - struct sysdb_ctx **_ctx); - errno_t sysdb_add_to_domain(struct sss_domain_info *domain, struct sysdb_ctx *ctx); /* functions to retrieve information from sysdb |