Merge pull request #600 from weaveworks/599-close-nil-channel

Fix close on nil channel
This commit is contained in:
Paul Bellamy
2015-10-28 15:53:52 +00:00
2 changed files with 2 additions and 0 deletions

View File

@@ -94,6 +94,7 @@ func newConntrackFlowWalker(useConntrack bool, args ...string) flowWalker {
result := &conntrackWalker{
activeFlows: map[int64]flow{},
args: args,
quit: make(chan struct{}),
}
go result.loop()
return result

View File

@@ -92,6 +92,7 @@ func TestConntracker(t *testing.T) {
}
flowWalker := newConntrackFlowWalker(true)
defer flowWalker.stop()
// First write out some empty xml for the existing connections
ecbw := bufio.NewWriter(existingConnectionsWriter)