s3: Fix bug 7843: Expand the local SAMs aliases
authorJeremy Allison <jra@samba.org>
Sun, 5 Dec 2010 19:40:21 +0000 (20:40 +0100)
committerKarolin Seeger <kseeger@samba.org>
Sat, 5 Mar 2011 13:34:40 +0000 (14:34 +0100)
(cherry picked from commit 50c8b426385df953d2e3748a39041d4b92cd7ed9)

source3/winbindd/wb_gettoken.c

index ca407b2117022a0a7b1667f0ab0f3d3d0315a435..f2fbe4c09519ea77d83ff76ba5b086736e534e12 100644 (file)
@@ -106,7 +106,7 @@ static void wb_gettoken_gotgroups(struct tevent_req *subreq)
        /*
         * Expand our domain's aliases
         */
-       domain = find_our_domain();
+       domain = find_domain_from_sid_noinit(get_global_sam_sid());
        if (domain == NULL) {
                tevent_req_nterror(req, NT_STATUS_INTERNAL_ERROR);
                return;
@@ -137,7 +137,7 @@ static void wb_gettoken_gotlocalgroups(struct tevent_req *subreq)
                tevent_req_nterror(req, status);
                return;
        }
-       domain = find_our_domain();
+       domain = find_domain_from_sid_noinit(get_global_sam_sid());
        if (!wb_add_rids_to_sids(state, &state->num_sids, &state->sids,
                                 &domain->sid, num_rids, rids)) {
                tevent_req_nterror(req, NT_STATUS_NO_MEMORY);