Thanks, that is a nice example.
I don't see anything in there to handle the case where the client is pushing audio data at the server faster than the server is playing it (to prevent lag buildup)... in theory the sample rates are the same, but... in the other case, the player will stop when it runs out of data, but if the buffer is getting filled too quickly?