Board index » cppbuilder » Flushing ClientSocket's receive buffer?

Flushing ClientSocket's receive buffer?


2003-10-24 05:35:58 PM
cppbuilder56
Hi all,
I'm using a TClientSocket to connect to some industrial system. It's running
in non-blocking mode. During communication in some cases I don't want to
read the reveived data. What do I have to do to discard the received data
when entering the OnRead-event? Is there some function like
MyClientSocket->Flush()? Or is the receive buffer emptied automatically when
leaving the OnRead-event? I didn't find any informations about this.
Thanks in advance
Soeren
 
 

Re:Flushing ClientSocket's receive buffer?

"Soren Zimmermann" < XXXX@XXXXX.COM >wrote in message
Quote
What do I have to do to discard the received data when
entering the OnRead-event? Is there some function like
MyClientSocket->Flush()?
No. You'll just have to read the socket and then ignore what you read.
Quote
Or is the receive buffer emptied automatically when leaving
the OnRead-event?
No.
Gambit