diff --git a/conn_linux.go b/conn_linux.go index aa55831..8f63dbd 100644 --- a/conn_linux.go +++ b/conn_linux.go @@ -134,6 +134,10 @@ func (c *conn) Receive() ([]Message, error) { bufPtr := c.bufPool.Get().(*[]byte) b := (*bufPtr)[:os.Getpagesize()] defer func() { + // Reset buffer content. + for i := 0; i < len(b); i++ { + b[i] = 0 + } c.bufPool.Put(bufPtr) }()