Re: [twsocket] SmtpClient problem on disconnect

2006-11-17 Thread [EMAIL PROTECTED]
> We've been talking this topic many times. > The RFCs say that the server has to close the connection, so if > a server doesn't close the connection on receiving command QUIT > the server is buggy. You can handle those server-side bugs with a simple > command timeout, in real applications some a

[twsocket] Pulling my hair out trying to receive a record

2006-11-17 Thread Clay Shannon
I am trying to test sending records from a utility to my app, which should receive and process the records. I am able to send the record from my test utility with this code: procedure TForm10.btnSendMsgAsRecordClick(Sender: TObject); begin InitializeWSocketProperties; WSocket_AsClien

Re: [twsocket] Telnet problems

2006-11-17 Thread Francois Piette
I think TTnScript is the way to go. You can dynamically add/remove events according to which "screen" you detect. If you don't use TTnScript, has a look at his source code to understand how to get hand on the input stream to chack for data. I also uploaded a modified version of the components. It

Re: [twsocket] SmtpClient problem on disconnect

2006-11-17 Thread Francois Piette
In my opinion, the servers are not compliant with the standard. Indtead of tweaking the component, either simply colse the connection yourself or implement a timeout and close it later if the server don't do it quickly enough for you. Contribute to the SSL Effort. Visit http://www.overbyte.be/eng/

Re: [twsocket] HttpCli & ContentRangeBegin

2006-11-17 Thread Cosmin Prund
Francois PIETTE wrote: >> (3) In the code running after a failed download I'm removing the last >> portion of the received data, just in case it's corrupted. I noticed >> this behavior in a freeware download manager I used to use some time >> ago. But now I'm asking: is this really necessary? HTTP

Re: [twsocket] SmtpClient problem on disconnect

2006-11-17 Thread Arno Garrels
David A. G. wrote: > Hello all: > > I'm having problems SmtpCli where OnRequestDone function is not fired > after sending QUIT command because the SMTP server is not closing the > connection!!. We've been talking this topic many times. The RFCs say that the server has to close the connection, so

[twsocket] Need example code for identifying a record before processing

2006-11-17 Thread Clay Shannon
I will be receiving a variety of structs/records, all of different sizes and "makeups". How can I (in the OnDataAvailable() handler, I assume), determine/identify which record has just come in, so that I can process it accordingly? OnDataAvailable() should only fire once for each record, b

[twsocket] Shutdown(How: Integer)

2006-11-17 Thread Clay Shannon
When do I need, or would I want, to call Shutdown(), and what are the ramifications of the different parameters that one can pass it. I see Shutdown(2) in one of the demo apps, but don't know what "2" represents. The information transmitted is intended only for the person or entity to which it

[twsocket] Telnet problems

2006-11-17 Thread Humm, Markus
Hello, I've some big problems with the telnet components, the biggest one being the lack of documentation. What I want to do is the following: 1. start a telnet session (that one works) 2. have a list of commands 3. loop through the list and carry out one command after the other 4. display th

[twsocket] SmtpClient problem on disconnect

2006-11-17 Thread David A. G.
Hello all: I'm having problems SmtpCli where OnRequestDone function is not fired after sending QUIT command because the SMTP server is not closing the connection!!. It occurs only when using EHLO command and AUTH LOGIN authentication. I have tryed with 2 servers with same results (big linux se

Re: [twsocket] Connection catch-22

2006-11-17 Thread Francois Piette
> When I call TWSocket's Send method, I'm getting error 10057, > "Send Socket is not connected" It is because you call Send immediately after Calling Connect. TWSocket is a NON-BLOCKING component. When you call Connect, you get control back immediately (the next line execute immediately) while the

Re: [twsocket] HttpCli & ContentRangeBegin

2006-11-17 Thread Francois PIETTE
> (1) What happens if I use ContnetRangeBegin and the server doesn't > support ranges (ex: if I'm downloading the results of a script)? Will I > end up with the whole document append to the already downloaded portion > of the document? You'll get an error. > (2) I noticed there's a AcceptRanges p