raul
a21199a6e0
The receiveMessage() function would regularly keep casting strings based on a 2048 byte array, this didn't seemingly pose a problem until I noticed the RAM usage go through the roof when the client had to be populated with the chat history of a lengthy chat log by the server. To fix this I am now creating a second array using the number of bytes being returned by the Read() method and copying the 2048 byte array's contents into it, setting the former array to nil afterwards. |
||
---|---|---|
.. | ||
client.go | ||
clientFunc.go | ||
gen-cert.sh | ||
root.go | ||
server.go | ||
serverFunc.go |