WSPSend: problem in returning without really send data

May 19th, 2008 - 02:47 pm ET by CyberPK | Report spam
I need to fake the original WSPSend to make the program think that all
data were sent.
So i've set *NumberOfBytesSent to le total buffer length, *lpErrno =0,
and returned 0.
It works perfectly with IE, but fails with other browaser like
firefoxand opera.
After the WSPSend, IE go straigth no and call the recive function.
Firefox and opera not. I've tried to pass the send to the lower
povider and it work.
Firefox wait something like 3 minutes and then call the recive
function.
I thinked to something that timeout. So i've twice cheched that either
firefox and opera didn't sent an lpOverlapped and an
lpCompletationRoutine structure. They are both null in both the
browser.
I thinked to a problem with the NumberOfBytesSent, but if it is lower
than expected the send function should be recalled. It's really
strange! Why ie works and firefox and opera not? They seem
to wait something to understand that the WSPSend is over!
email Follow the discussionReplies 5 repliesReplies Make a reply

Replies

#1 CyberPK
June 04th, 2008 - 02:48 pm ET | Report spam
On 23 Mag, 01:00, David Schwartz wrote:
On May 22, 6:02 am, wrote:

> Summing the len of each buffer present into the WSABUF structure.
> Somethink like that:
> ULONG lenght = 0;
> for(DWORD i = 0; i < dwBufferCount; i++) length += lpBuffer[i].len;

That should be fine. So long as both completion pointers are NULL, I
can't imagine what you could be doing wrong.

DS



I've understood the problem.
Seem that firefox call the wspselect() function to know the status of
the socket.
If it is readeable, then call the recv function.
So, how to se the status of the socket to readeable??

Similar topics