iosobjective-cxcodensurlconnectionsendasynchronousrequest

Error message : [MC] Reading from public effective user settings & [MC] System group container for systemgroup.com.apple.configurationprofiles path is


When I use the following code, I have error messages :

[NSURLConnection sendAsynchronousRequest:request queue:myQueue completionHandler:^(NSURLResponse *response, NSData *data, NSError *error) {
        NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
        NSLog(@"response status code: %ld, error status : %@", (long)[httpResponse statusCode], error.description);

        if ((long)[httpResponse statusCode] >= 200 && (long)[httpResponse statusCode]< 400)
            {
               // do stuff
                [self requestFunction]; //Web Service
            }
}];

Error messages :

2017-02-27 01:13:30.088641 RENAULT[210:12313] [MC] System group container for systemgroup.com.apple.configurationprofiles path is /private/var/containers/Shared/SystemGroup/systemgroup.com.apple.configurationprofiles
2017-02-27 01:13:30.090449 RENAULT[210:12313] [MC] Reading from public effective user settings.

The [self requestFunction] function launch a simple request :

        NSMutableURLRequest* request = [[NSMutableURLRequest alloc] init];
        NSString *url_string = [bytes stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
        [request setURL:[NSURL URLWithString:[set_send_order stringByAppendingString: url_string]]];
        [request setCachePolicy:NSURLRequestReloadIgnoringLocalCacheData];
        [request setTimeoutInterval:timeOut];
        [NSURLConnection connectionWithRequest:request delegate:self]; 

I precise that the connectionDidFinishLoading: is not called, but if I launch it directly without the sendAsynchronousRequest:, it works. So why the fact that I use sendAsynchronousRequest: function makes me appear the two error messages, and the miscalling of the connectionDidFinishLoading ?

Thank you in advance.


Solution

  • It occurs to me. The same logs in console when I use textField. Follow is my operation:

    I solved it thanks to this discussion.