0
Answer

Need help with incoming chat protocols.

Ask a question
Brian

Brian

15y
2k
1
Hello, i've been wracking my brain trying to figure this out but, alas, i cannot.  What i'm trying to do is for a chat client i'm making for my favourite chat system.  There protocols are not ended by the end of a packet received, but ended with a line feed character ("\n").  So a protocol command can come in on multiple packets.  So just doing  a straight receive of data and process doesn't work, what i need is some form of buffer to store all the data in and parse through it by line feed's and then process each command.  I've tried multiple ways of doing this but none work.  If anyone has any idea's or suggestions i'd greatly appreciate it.

- Brian Sykes