Keith Willis wrote:

> I have managed to improve the code reliability by not dynamically
> allocating the PostedDataBuffer at all, (but this is not an
> acceptable solution). In the code snippets below I pre-allocate once
> in the constructor but this still generates AV's.

You never check PostedDataSize, the size of your receive buffer.
The pascal demo allocates this buffer dynamically depending on the
RequestContentLength plus one byte for the null terminator in the
OnPostDocument event handler.
What is the value of RcvdByteCount when the error happens?

Arno Garrels
To unsubscribe or change your settings for TWSocket mailing list
please goto
Visit our website at

Reply via email to