s3: winbindd_cli_state->getgrent_state is no longer used
authorVolker Lendecke <vl@samba.org>
Thu, 24 Dec 2009 11:52:00 +0000 (12:52 +0100)
committerVolker Lendecke <vl@samba.org>
Sat, 26 Dec 2009 11:26:06 +0000 (12:26 +0100)
source3/winbindd/winbindd.c
source3/winbindd/winbindd.h
source3/winbindd/winbindd_proto.h
source3/winbindd/winbindd_util.c

index 3f7a44e9dc97c1afd71379a23d864484b4533a53..e31103a9411d01eaafbcf0494740081cfa865b9c 100644 (file)
@@ -835,10 +835,6 @@ static void remove_client(struct winbindd_cli_state *state)
                state->sock = -1;
        }
 
-       /* Free any getent state */
-
-       free_getent_state(state->getgrent_state);
-
        TALLOC_FREE(state->mem_ctx);
 
        /* Remove from list and free */
index e58230225bee52d4c08ffd0987fd6977298c3805..99fa10250ae12f9236b52d7748ea2a52473e2cf6 100644 (file)
@@ -65,22 +65,11 @@ struct winbindd_cli_state {
                                                   * initialized? */
        bool getgrent_initialized;                /* Has getgrent_state been
                                                   * initialized? */
-       struct getent_state *getgrent_state;      /* State for getgrent() */
 
        struct getpwent_state *pwent_state; /* State for getpwent() */
        struct getgrent_state *grent_state; /* State for getgrent() */
 };
 
-/* State between get{pw,gr}ent() calls */
-
-struct getent_state {
-       struct getent_state *prev, *next;
-       void *sam_entries;
-       uint32 sam_entry_index, num_sam_entries;
-       bool got_sam_entries;
-       fstring domain_name;
-};
-
 struct getpwent_state {
        struct winbindd_domain *domain;
        int next_user;
index cb3e84184c84b2c8b985d3d6b5de6c0e3d13fe16..012e3b6332eac2ba9785aaee84a2996d9e403cb1 100644 (file)
@@ -428,7 +428,6 @@ struct winbindd_domain *find_root_domain(void);
 struct winbindd_domain *find_builtin_domain(void);
 struct winbindd_domain *find_lookup_domain_from_sid(const DOM_SID *sid);
 struct winbindd_domain *find_lookup_domain_from_name(const char *domain_name);
-void free_getent_state(struct getent_state *state);
 bool parse_domain_user(const char *domuser, fstring domain, fstring user);
 bool parse_domain_user_talloc(TALLOC_CTX *mem_ctx, const char *domuser,
                              char **domain, char **user);
index c92e11aba3c9d2c27ee3f63249c55f67bb59285b..8c21ed66108c5a29b3df774fc3fe3a991af630c1 100644 (file)
@@ -868,29 +868,6 @@ struct winbindd_domain *find_lookup_domain_from_name(const char *domain_name)
        return find_our_domain();
 }
 
-/* Free state information held for {set,get,end}{pw,gr}ent() functions */
-
-void free_getent_state(struct getent_state *state)
-{
-       struct getent_state *temp;
-
-       /* Iterate over state list */
-
-       temp = state;
-
-       while(temp != NULL) {
-               struct getent_state *next = temp->next;
-
-               /* Free sam entries then list entry */
-
-               SAFE_FREE(state->sam_entries);
-               DLIST_REMOVE(state, state);
-
-               SAFE_FREE(temp);
-               temp = next;
-       }
-}
-
 /* Is this a domain which we may assume no DOMAIN\ prefix? */
 
 static bool assume_domain(const char *domain)