mirror of https://github.com/gorilla/websocket.git
fix: add comment for the readBufferSize and writeBufferSize (#869)
### summary
😅 Every time I use `gorilla/websocket`, I need to look at the source
code and find the default size for readBufferSize and writeBufferSize.
I think the default value should be written in the comment.
Signed-off-by: rfyiamcool <rfyiamcool@163.com>
Co-authored-by: Alex Vulaj <ajvulaj@gmail.com>
This commit is contained in:
parent
286c896192
commit
01b0aaed92
|
@ -34,6 +34,7 @@ type Upgrader struct {
|
||||||
// size is zero, then buffers allocated by the HTTP server are used. The
|
// size is zero, then buffers allocated by the HTTP server are used. The
|
||||||
// I/O buffer sizes do not limit the size of the messages that can be sent
|
// I/O buffer sizes do not limit the size of the messages that can be sent
|
||||||
// or received.
|
// or received.
|
||||||
|
// The default value is 4096 bytes, 4kb.
|
||||||
ReadBufferSize, WriteBufferSize int
|
ReadBufferSize, WriteBufferSize int
|
||||||
|
|
||||||
// WriteBufferPool is a pool of buffers for write operations. If the value
|
// WriteBufferPool is a pool of buffers for write operations. If the value
|
||||||
|
|
Loading…
Reference in New Issue