diff options
author | Simo Sorce <ssorce@redhat.com> | 2009-12-18 10:23:41 -0500 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2009-12-18 15:41:36 -0500 |
commit | 3a1f8aa6f6464d8e80b79664e204ca3b24663e00 (patch) | |
tree | 616eca757c8807a3a0ee97c12ff97b10a9041441 /server/providers/ldap/sdap_async_private.h | |
parent | 172ed348f92121f6c17433a65815d5f5cc81d626 (diff) | |
download | sssd-3a1f8aa6f6464d8e80b79664e204ca3b24663e00.tar.gz sssd-3a1f8aa6f6464d8e80b79664e204ca3b24663e00.tar.xz sssd-3a1f8aa6f6464d8e80b79664e204ca3b24663e00.zip |
Fix ldap child memory hierarchy and other issues
The timeout handler was not a child of the request so it could fire even though
the request was already freed.
The code wouldn't use async writes to the children so it could incur in a short
write with no way to detect or recover from it.
Also fixed style of some helper functions to pass explicit paramters instead of
a general structure.
Add common code to do async writes to pipes.
Fixed async write issue for the krb5_child as well.
Fix also sdap_kinit_done(), a return statement was missing and we were mixing
SDAP_AUTH and errno return codes in state->result
Remove usless helper function that just replicates talloc_strndup()
Diffstat (limited to 'server/providers/ldap/sdap_async_private.h')
-rw-r--r-- | server/providers/ldap/sdap_async_private.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/server/providers/ldap/sdap_async_private.h b/server/providers/ldap/sdap_async_private.h index af8d2b8e4..9237f15d4 100644 --- a/server/providers/ldap/sdap_async_private.h +++ b/server/providers/ldap/sdap_async_private.h @@ -44,16 +44,16 @@ int sdap_get_rootdse_recv(struct tevent_req *req, /* from sdap_child_helpers.c */ -struct tevent_req *sdap_krb5_get_tgt_send(TALLOC_CTX *mem_ctx, - struct tevent_context *ev, - int timeout, - const char *realm_str, - const char *princ_str, - const char *keytab_name); - -int sdap_krb5_get_tgt_recv(struct tevent_req *req, - TALLOC_CTX *mem_ctx, - int *result, - char **ccname); +struct tevent_req *sdap_get_tgt_send(TALLOC_CTX *mem_ctx, + struct tevent_context *ev, + const char *realm_str, + const char *princ_str, + const char *keytab_name, + int timeout); + +int sdap_get_tgt_recv(struct tevent_req *req, + TALLOC_CTX *mem_ctx, + int *result, + char **ccname); #endif /* _SDAP_ASYNC_PRIVATE_H_ */ |