Skip to content

examples/chat/client.go: avoid allocating []byte{} for PingMessage - #312

Merged
1 commit merged into
gorilla:masterfrom
JordanP:patch-1
Dec 10, 2017
Merged

1 commit merged into
gorilla:masterfrom
JordanP:patch-1

Conversation

@JordanP

@JordanP JordanP commented Dec 9, 2017

Copy link
Copy Markdown
Contributor

It's useless and only gives more work to the GC.

It's useless and only gives more work to the GC.
@ghost

ghost commented Dec 9, 2017 •

Copy link
Copy Markdown

[]byte{} does not allocate memory. I'll merge because the code is simpler.

@ghost
ghost merged commit cdedf21 into gorilla:master Dec 10, 2017
@JordanP
JordanP deleted the patch-1 branch December 10, 2017 10:05
@ghost ghost locked and limited conversation to collaborators Aug 29, 2018
This pull request was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant