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!
On May 19, 11:47 am, Cybe...@gmail.com wrote: > 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. How are you computing the total buffer length? DS
Do not multipost. Cross post instead. Read my reply at microsoft.public.win32.programmer.networks -- V. This posting is provided "AS IS" with no warranties, and confers no rights. wrote in message news:f7023fa5-869f-429f-b084-213b61162d1b@z72g2000hsb.googlegroups.com... >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!
On 20 Mag, 10:32, David Schwartz wrote: > On May 19, 11:47 am, Cybe...@gmail.com wrote: > > > I need to fake the originalWSPSendto 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. > > How are you computing the total buffer length? > > DS 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;
On May 22, 6:02 am, Cybe...@gmail.com 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
On 23 Mag, 01:00, David Schwartz wrote: > On May 22, 6:02 am, Cybe...@gmail.com 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??