summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2017-06-12 23:40:25 +0200
committerDimitri Sokolyuk <demon@dim13.org>2017-06-12 23:40:25 +0200
commitf66f53a2e45eb016e5cb2d10dd4debd03ee32b9e (patch)
tree0dd17677f3d8530a1bc1fe618a968e50190393ad
parent36980cb78dacdddd6f216f4e2d063cefcf53c21f (diff)
Larger window
-rw-r--r--main.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.go b/main.go
index d6effe7..cc69baf 100644
--- a/main.go
+++ b/main.go
@@ -34,7 +34,7 @@ type Data struct {
func dump(dir Direction, src, dst net.Conn, data chan<- Data) error {
//buf := make([]byte, 1452)
- buf := make([]byte, 1)
+ buf := make([]byte, 10)
for k := 1; ; k++ {
now := time.Now()
n, err := src.Read(buf)
@@ -71,7 +71,7 @@ func main() {
}
defer cnt.Close()
- data := make(chan Data)
+ data := make(chan Data, 1)
wg.Add(2)
go func() {