Fix winbindd crash bug with trusted domains. Bug #5736
authorJames Ding <ding_cc@hotmail.com>
Thu, 4 Sep 2008 22:17:18 +0000 (15:17 -0700)
committerKarolin Seeger <kseeger@samba.org>
Mon, 8 Sep 2008 09:24:39 +0000 (11:24 +0200)
(cherry picked from commit 2d84b9a1024f68657f75aa7e0c4091b8c7afd194)

source/winbindd/winbindd_ads.c

index 5b651fa..c588726 100644 (file)
@@ -1225,6 +1225,8 @@ static NTSTATUS trusted_domains(struct winbindd_domain *domain,
                for (i = 0; i < trusts.count; i++) {
                        struct winbindd_domain d;
                        
                for (i = 0; i < trusts.count; i++) {
                        struct winbindd_domain d;
                        
+                       ZERO_STRUCT(d);
+
                        /* drop external trusts if this is not our primary 
                           domain.  This means that the returned number of 
                           domains may be less that the ones actually trusted
                        /* drop external trusts if this is not our primary 
                           domain.  This means that the returned number of 
                           domains may be less that the ones actually trusted