Fix memory leak in error path, spotted by Martin Zielinski <mz@seh.de>.
authorJeremy Allison <jra@samba.org>
Wed, 12 Nov 2008 22:03:54 +0000 (14:03 -0800)
committerJeremy Allison <jra@samba.org>
Wed, 12 Nov 2008 22:03:54 +0000 (14:03 -0800)
Jeremy.

source/winbindd/winbindd_passdb.c

index 5677c01be140232fdf66687d73137aa868905274..0cf4540cfef02ee0bd0972e614740a76ce776fd0 100644 (file)
@@ -267,6 +267,7 @@ static NTSTATUS lookup_usergroups(struct winbindd_domain *domain,
        }
 
        if ( !pdb_getsampwsid( user, user_sid ) ) {
+               TALLOC_FREE( user );
                return NT_STATUS_NO_SUCH_USER;
        }