Thanks for your reply!

Arno Garrels wrote:
> You get a real infinite loop only if you called Receive() with a buffer
> size of zero.
>   
Which is not the case
>  
>   
>> The thing is that we _always_ call ReceiveStr() in the OnDataAvailable
>> event, I think this should always read all data received.
>>     
>
> Depends on LineMode, if LineMode is TRUE ReceiveStr() just reads a
> single line.
>   
LineMode is false
> I don't think it's a bug, wsoNoReceiveLoop is an option turned off
> by default for backwards compatibility.  
>
>   
I'm really looking for an explanation of what happened, so I can confirm 
the bug is really fixed.

Facts:
- 100% cpu utilization caused by OnDataAvailable being called in a loop 
(sync, so no change for the message pump to work)
- Linemode = false
- we call ReceiveStr() on _every_ OnDataAvailable event
- when wsoNoReceiveLoop is set, we don't have this problem anymore

these things seem to contradict each other? It of course is possible 
that with wsoNoReceiveLoop set we still have the same problem, but we 
don't notice it because the message pump has a change to kick in.
Is there any way I can get my fingers around this? Reading it all again, 
I'm still coming to the same conclusion: either bug in ReceiveStr(), bug 
in handling of wsoNoReceiveLoop, or me being stupid and don't 
understanding things correctly.

Can anybody shed some light? :p
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to