0

I have the following code

dispatch_queue_t dispatch_get_local_queue()
{
    static dispatch_queue_t _queue;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        _queue = dispatch_queue_create("com.github.blackraccoon", 0);
        dispatch_queue_set_specific(_queue, "com.github.blackraccoon", (void*) "com.github.blackraccoon", NULL);
    });
    return _queue;
}

after received signal EXC BAD ACCESS at line dispatch_queue_set_specific. how to handle this? and everything work fine with iphone 5.0 simulator. but crashes with iphone 4.3 simulator and ipad with ios 4.2. it is part of BlackRaccoon project. after I

createDir = [BRRequestCreateDirectory initWithDelegate: self];
createDir.path = [NSString stringWithFormat:@"/%@/",strProjectID];
createDir.hostname = @"cite";
createDir.username = @"username";
createDir.password = @"password";
[createDir start];
Cœur
  • 37,241
  • 25
  • 195
  • 267
ij_
  • 239
  • 1
  • 3
  • 11

1 Answers1

3

It is important to read the documentation.

Availability
Available in iOS 5.0 and later.

Your options are:

  • Try to modify the library yourself to work on older devices
  • File an issue on the github project to support older versions
  • Use another project that supports iOS 4
Joe
  • 56,979
  • 9
  • 128
  • 135