iphone - Timeout doesn't work properly in the NSMutableURLRequest. But, why? -



iphone - Timeout doesn't work properly in the NSMutableURLRequest. But, why? -

nsmutabledictionary* headers = [[[nsmutabledictionary alloc] init] autorelease]; [headers setvalue:@"application/x-www-form-urlencoded;charset=utf-8" forkey:@"content-type"]; [headers setvalue:@"text/html" forkey:@"accept"]; [headers setvalue:@"no-cache" forkey:@"cache-control"]; [headers setvalue:@"no-cache" forkey:@"pragma"]; [headers setvalue:@"close" forkey:@"connection"]; nsmutableurlrequest *request = [nsmutableurlrequest requestwithurl:url cachepolicy:nsurlrequestuseprotocolcachepolicy timeoutinterval:timeout_request]; [request sethttpmethod:@"post"]; [request setallhttpheaderfields:headers]; [request sethttpbody:body]; [self createconnectionwithrequest:request delegate:delegate];

my timeout_request=30 seconds , i'm waiting 80 seconds before i'll didfailwitherror. but, why?

iphone nsurlrequest nsmutableurlrequest

Comments

Popular posts from this blog

java - How to pass parameters between Request-Scoped Controllers? -

actionscript 3 - Flex: moving a point with rotation doesnt change the point XY? -

string - what is the difference between "some" == "some\0" and strcmp("some","some\0") in c++? -