iOS memory leaks for basic calls like [serviceAPI buildUserService];

0 votes
Hi,

 

I am testing simple code as suggested in the tutorials, under Xcode 5.1 with ARC enabled.

 

I get memory leaks from objects like:

UserService

StorageService

and some [SBJSONParser scanRestOfString:], etc.

 

Any ideea how to remove the leaks ?

 

I have tried alternatives with disabling ARC and releasing manually the objects and with ARC enabled and =nil statements at the end but none seems to work.

 

Maybe it is an easy question in which case, sorry to bother.

 

Many thanks,

Horia
asked Sep 30, 2014 in App42 Cloud API-BaaS by horia.velicu (10 points)

1 Answer

0 votes

Hi,

Basically, we use buildUserService method to create and configure UserService instance. Also it is not going to impact the app memory on large scale unless it is called frequently in a loop.

But we do have an alternate way to avoid this case, instead of using buildUserService method, you can create UserService instance as follows:

UserService *userService = [[UserService alloc] initWithAPIKey:@"APP_Key" secretKey:@"SECRET_Key"];

Please let us know if the problem continues.

Thanks.

 

answered Sep 30, 2014 by rajeev.etc (1,660 points)
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...