diff options
author | Pavel Březina <pbrezina@redhat.com> | 2012-12-14 12:29:50 +0100 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2012-12-18 17:15:22 +0100 |
commit | e5c9834c45849cbf82ea420fa3e0efdc102cc26e (patch) | |
tree | 285928a52a9030b8cdd6986e1c8824e8ebb86e3c /src/providers | |
parent | 260366c37cafab011cf48760eaf04282098ef800 (diff) | |
download | sssd-e5c9834c45849cbf82ea420fa3e0efdc102cc26e.tar.gz sssd-e5c9834c45849cbf82ea420fa3e0efdc102cc26e.tar.bz2 sssd-e5c9834c45849cbf82ea420fa3e0efdc102cc26e.zip |
check dp error in sdap_sudo_full_refresh_done()
https://fedorahosted.org/sssd/ticket/1689
Diffstat (limited to 'src/providers')
-rw-r--r-- | src/providers/ldap/sdap_sudo.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/providers/ldap/sdap_sudo.c b/src/providers/ldap/sdap_sudo.c index 2c6c7712..c4f422ed 100644 --- a/src/providers/ldap/sdap_sudo.c +++ b/src/providers/ldap/sdap_sudo.c @@ -615,9 +615,8 @@ static void sdap_sudo_full_refresh_done(struct tevent_req *subreq) ret = sdap_sudo_refresh_recv(state, subreq, &state->dp_error, &state->error, &highest_usn, NULL); talloc_zfree(subreq); - if (ret != EOK) { - tevent_req_error(req, ret); - return; + if (ret != EOK || state->dp_error != DP_ERR_OK || state->error != EOK) { + goto done; } state->sudo_ctx->full_refresh_done = true; @@ -639,6 +638,12 @@ static void sdap_sudo_full_refresh_done(struct tevent_req *subreq) sdap_sudo_set_usn(state->id_ctx->srv_opts, highest_usn); } +done: + if (ret != EOK) { + tevent_req_error(req, ret); + return; + } + tevent_req_done(req); } |