torture: fixed socket leak in BENCH-TCON test
authorAndrew Tridgell <tridge@samba.org>
Mon, 12 Oct 2009 05:11:53 +0000 (16:11 +1100)
committerKarolin Seeger <kseeger@samba.org>
Thu, 26 Nov 2009 10:39:14 +0000 (11:39 +0100)
The BENCH-TCON test was leaving the socket open. A smbclie_tdis()
closes the tree connection, but does not close the socket.

This caused the build farm to run out of file descriptors
(cherry picked from commit f1529c3223a4b366cd4795c559eaaa8c40078470)

source4/torture/raw/tconrate.c

index 076e5be31ff4150c6cfe93af508afbe8c1ae6ba2..06cb7650c154711e44b138bb8f949a0fff31a164 100644 (file)
@@ -112,6 +112,7 @@ static int fork_tcon_client(struct torture_context *tctx,
                }
 
                smbcli_tdis(cli);
+               talloc_free(cli);
 
                *tcon_count = *tcon_count + 1;
                now = timeval_current();