Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Francois PIETTE
> I'd like to try your version, if you could send it to me, > I'd be glad, thanks You can download it from here: http://sme.scarlet.be/~vip107/WebServ.zip The url for your code is bruno.html from the root (see source). -- Contribute to the SSL Effort. Visit http://www.overbyte.be/eng/ssl.html --

Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
François: I've downloaded it, and got the same thing. I disabled Windows Firewall, but nothing changed. I've uploaded an image in http://www.revolution.com.br/icsscreen.zip It has a readme and some marked areas to show what happen here. Bruno On 22/5/2005 05:08:53, Francois PIETTE ([EMAIL PROTE

Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Francois PIETTE
I have real world applications running with the HTTP server component and they have no problem at all. So it must be something on your system. Do you have another computer to test with ? Can you make the server run on one computer and the browser on the other ? Can you use a sniffer to check that

Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
My system has all updates, but this happens also on other machines (I can put the server in my machine or in other machines and the same happens). The program runs fine, just the connection isn't closed, you can have many connections open at the same time, when they are not needed. The strangest

Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Francois PIETTE
> The program runs fine, just the connection isn't closed, you can have many > connections open at the same time, when they are not needed. The strangest > thing is that it happens only in some machines (that's why you're not seeing > it), in IE only and with virtual pages, not document pages. Vir

Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Wilfried Mestdagh
Hello Bruno, I just downloaded the demo from Francois, and tryed the server on 3 different machines (NT, W2K, XP), and every time connected with the 3 machines with IE (different versions) to the server/bruno.html. Works every time here. Also I have a several project with the HttpSrv without pro

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
I begin to think that this is the problem - I was thinking two options: something with the Brazilian Portuguese version of IE, or something with a program that intercepts communications, like an antivirus. The only questions that remain are: why does this happen only with virtual pages and not wit

Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
François: > Virtual pages and document pages are the same. Virtual pages use a > TMemoryStream with your data with document page use a TFileStream. Yes, I know, but the behavior is very consistent to be just coincidence. I've tried to follow ICS' source code to see any differences, but there was

Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Wilfried Mestdagh
Hello Bruno, >> Can I remotely access your computer to try webserv ? > I'm afraid this will be impossible, I'm behind my ISP's firewall and I > cannot change it. Some ISP block port, but not all port, probably all above 1024 is open, so you can listen on an alternative port (not 80) to do the te

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Francois PIETTE
> The only questions that remain are: why does this happen only with virtual > pages and not with documents? You can easily built a dynamic page that return exactly the same informations than a static page. If you try that, verify using a sniffer that the output is exactly the same. > Why does th

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
Finally, I could find what was causing the problem here - I still don't know why, but at least I could fix it. I analyzed the header files sent by a virtual page and an identical real page. The difference was the virtual page was not sending three lines: Accept-Ranges: bytes Last-Modified: Sun,

Re: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Francois PIETTE
> Yes, I know, but the behavior is very consistent to be just coincidence. Does it depends on the size of the page ? You send 5000 lines in your test but what is the minimal size to experience the problem ? -- [EMAIL PROTECTED] http://www.overbyte.be -- To unsubscribe or change your settings fo

Re[4]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Wilfried Mestdagh
Hello Bruno, I'm just bsy in a rather large project using THttpSrv, and this is exact copy of what I send in all my virtual pages: Header := Cli.Version + ' 200 OK'#13#10 + 'Content-Type: text/html'#13#10 + 'Content-Length: ' + IntToStr(DocLen) + #13#10 +

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Francois PIETTE
> Finally, I could find what was causing the problem here - I still don't know > why, but at least I could fix it. > > I analyzed the header files sent by a virtual page and an identical real > page. The difference was the virtual page was not sending three lines: > > Accept-Ranges: bytes > Last-Mo

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
François: I finally managed to track what is happening here - in Internet options, if "Use HTTP 1.1" is unchecked, this behavior occurs when there is no "Connection:" in the header, thus causing this problem when virtual pages are sent. Bruno On 22/5/2005 16:11:43, Francois PIETTE ([EMAIL PROTEC

Re: Re[4]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
Wilfried: I think the problem is not with the size of the documents - I've had some problem with the Time demo, which is very small. Try this - go to Internet Options, Advanced, and uncheck Use HTTP 1.1. With your header, the server you are developing should show the same behavior I've seen. But

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
> In THttpConnection.AnswerStream, add the following block just after the > lines with Content-Length: > > if FKeepAlive then > PutStringInSendBuffer('Connection: Keep-Alive' + #13#10) > else > PutStringInSendBuffer('Connection: Close' + #13#10); > > Tell me if it works without adding the header

Re: Re[2]: [twsocket] Connection not closed in WebServer with IE

2005-05-22 Thread Bruno Sonnino
Taking a look at SendDocument, I saw this: { *DAVID* Revised this if/then/else } if FVersion = 'HTTP/1.0' then begin if CompareText(FRequestConnection, 'keep-alive') <> 0 then Header := Header + 'Connection: Close' + #13#10 else Header := Header + 'C