Re: [fpc-pascal] Cannot reuse TFPHTTPClient object for 2 different POST requests

2015-01-18 Thread Michael Van Canneyt
On Sun, 18 Jan 2015, leledumbo wrote: Yes, I can. The TFPHTTPClient instance is not stateless. Before doing a call, some headers are added to the request headers if they are not there yet. For example, the Content-Size header. But the Content-Size header is not added if is already present. F

Re: [fpc-pascal] Cannot reuse TFPHTTPClient object for 2 different POST requests

2015-01-18 Thread leledumbo
> Yes, I can. The TFPHTTPClient instance is not stateless. > > Before doing a call, some headers are added to the request headers if they > are not there yet. > For example, the Content-Size header. > > But the Content-Size header is not added if is already present. > For calls 1 and 2 it doe

Re: [fpc-pascal] Cannot reuse TFPHTTPClient object for 2 different POST requests

2015-01-18 Thread Michael Van Canneyt
On Sun, 18 Jan 2015, leledumbo wrote: i was thinking that there's some sort of inbound traffic that may be filling a buffer that needs to be emptied... i don't know or have any other ideas to offer... Mmm...could be, that's what should be searched for. The problem is not in TFPHTTPClient.

Re: [fpc-pascal] Cannot reuse TFPHTTPClient object for 2 different POST requests

2015-01-18 Thread leledumbo
> i was thinking that there's some sort of inbound traffic that may be filling a buffer that needs to be emptied... i don't know or have any other ideas to offer... Mmm...could be, that's what should be searched for. > The problem is not in TFPHTTPClient. The problem is the data and/or URL > fo

Re: [fpc-pascal] Cannot reuse TFPHTTPClient object for 2 different POST requests

2015-01-18 Thread Michael Van Canneyt
On Fri, 16 Jan 2015, leledumbo wrote: Consider the following program (it's a real program with real parameters, nothing hidden, so you can really just try it out because the target server is public): The problem is not in TFPHTTPClient. The problem is the data and/or URL for request 3: if