I have 2 issues preventing the conversion to ARC tool from running on xCode 6.3.1

50 views Asked by At

Issue 1... Issue 1

There is a whole lot of these releases that were automatically created when I initially wrote this code several years ago. I am assuming that all the others will go away after running the ARC migration tool. Why is this one being singled out, and how do I fix it? Just delete the line manually, before running the tool?

Issue 2... enter image description here

Not sure what the error is trying to say. How do I fix it to comply with ARC?

Thanks,

John

1

There are 1 answers

0
user278859 On BEST ANSWER

Issue 1, not getting any response on this one, I just commented out the offending line and the tool no longer complained about it. So far no ill effects under ARC.

Issue 2, thanks to Michael, was resolved by moving the declarations of response and error to each method in question, ie from instance property to local var...

NSURLResponse *response;
NSError *error;
data = [NSURLConnection sendSynchronousRequest:request returningResponse:&response error:&error];

The class has several methods that calls NSURLConnection and so I declared them at the top of the class instead of in each method to be more efficient. Perhaps there is a better way to do this than in each method?