Buffer Management So now you've allocated memory and you want to read/write with it? The important things to keep in mind are make sure you keep track of the buffers you have allocated .. and always remember to _free_ them when the connection goes away don't keep copying it around! make them as big as you think pratical don't be afraid of using small (say 2/4k) buffers if you have many, many connections (say 20k) you'll have at least one buffer per connection (~40/80mb) Try to keep them around for the length of a write() - it'll make porting to other network frameworks easier