On Sun, 2020-05-24 at 12:26 +0000, bauss via Digitalmars-d-learn wrote: […]
Thanks for responding, much appreciated. > void handleConnections(TCPConnection connection) { > ... > } I guess I was looking for an example of what to put in this function! > auto buf = new ubyte[amount]; > > connection.read(temp); The documentation on read is sadly lacking :-( https://vibed.org/api/vibe.core.net/TCPConnection.read It seems to block pending filling all the spaces in the buffer. Not really very useful. I tried: connection.read(buffer, IOMode.once); but there seems no report on how many bytes were read, you have to guess by parsing the buffer and making assumptions. Unless I am missing something, which I really hope I am. > connection.write(buf); Not quite at that stage yet! […] -- Russel. =========================================== Dr Russel Winder t: +44 20 7585 2200 41 Buckmaster Road m: +44 7770 465 077 London SW11 1EN, UK w: www.russel.org.uk
signature.asc
Description: This is a digitally signed message part