U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » U++ MT-multithreading and servers » [Bug] Httprequest - consecutive requests contain parts of previous requests
[Bug] Httprequest - consecutive requests contain parts of previous requests [message #44574] Fri, 03 April 2015 15:24 Go to previous message
Zbych is currently offline  Zbych
Messages: 332
Registered: July 2009
Senior Member
Hi,

When I execute consecutive requests (e.g. multipart/post/multipart) they contain parts of previous requests.
Of course I can call Clear() between requests, but it closes connection as well.

Test code:
#include <Core/Core.h>

using namespace Upp;

CONSOLE_APP_MAIN
{
	StdLogSetup(LOG_FILE | LOG_CERR | LOG_TIMESTAMP);

	HttpRequest hr("http://posttestserver.com/post.php");
	hr.Trace();
	hr.KeepAlive();
	
	hr.New();
	hr.Part("field1", "Lorem ipsum dolor sit amet, consectetur adipiscing elit");
	hr.Part("field2", "sed do eiusmod tempor incididunt ut labore et dolore magna aliqua");
	RLOG(hr.Execute());
	
	hr.New();
	hr.Post("field1", "Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat");
	RLOG(hr.Execute());

	hr.New();
	hr.Part("field1", "Lorem ipsum dolor sit amet, consectetur adipiscing elit");
	hr.Part("field2", "sed do eiusmod tempor incididunt ut labore et dolore magna aliqua");
	RLOG(hr.Execute());
}

[Updated on: Fri, 03 April 2015 15:27]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: HttpRequest, Content-ID header in Part method
Next Topic: How to just Post data ?
Goto Forum:
  


Current Time: Sun Apr 26 21:46:51 GMT+2 2026

Total time taken to generate the page: 0.00566 seconds