12
  • This bug show only ocassionally The bug in xcode shows

exc_breakpoint (code=exc_i386_bpt, subcode=0x0)

This is the screenshot of the bug: enter image description here

Bonus: If anyone can tell me how to "copy" the error message it'll be appreciated

In immediate window the log says:

2012-06-04 12:08:17.097 BadgerNew[866:17003] Reachability Flag Status:-R -----l- networkStatusForFlags

The code around the project is pretty much fool proof. I am very surprised that we have a bug there.

+(NSString *) Json_StringGetter:(NSString *) URL{
    CM(@"Json string getter");
    NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:URL]];
    DLog(@"request:%@",request);
    PO(URL);
    PO(request);

    __block NSError *error=nil;
    __block NSURLResponse *urlresponse=nil;
    __block NSData *response = nil;
    __block NSString *json_string=nil;

    //[Tools computeTimeWithName:FUNC block:^{
        response= [NSURLConnection sendSynchronousRequest:request returningResponse:&urlresponse error:&error];
        json_string = [[NSString alloc] initWithData:response encoding:NSUTF8StringEncoding];
    //}];

    if (error) {
        DLog(@"error at jsonparser:%@",urlresponse);
        DLog(@"error at jsonparser:%@",error);
        DLog(@"I break points here");
    }

    return json_string;
}
Mick MacCallum
  • 129,200
  • 40
  • 280
  • 281
user4951
  • 32,206
  • 53
  • 172
  • 282
  • You'll need to provide a stacktrace in see what is happening. – trojanfoe Jun 04 '12 at 06:18
  • Well, I think [NSURLConnection sendSynchronousRequest is pretty much robust. When things go wrong it'll just fill error. My concern is internet wasn't working well when it happened. – user4951 Jun 04 '12 at 08:05
  • My issue was trying to reference a file that I had added to the project, but not added to the target bundle. – user Apr 03 '14 at 07:42

1 Answers1

2

The issue is I break when the URL is loading. That's why I got this issue.

It basically says that you press break point. If I just run the code without breaking this issue never show up.

user4951
  • 32,206
  • 53
  • 172
  • 282