Wednesday, 21 August 2013

Allocations using AFNetworking request

Allocations using AFNetworking request

I'm using AFNetworking to send requests but when the request finishes its
job I'm getting this memory allocations in instruments and they stay there
forever... If I try to start another request the application receives
memory warning several times and thus it's forced to close.
Graph Category Live Bytes # Living # Transitory Overall Bytes
# Overall # Allocations (Net / Overall)
1 CFString (store) 4,86 MB 29 3595 30,78 MB 3624
<XRRatioObject: 0x7ffd1c5dc3f0> %0.00, %0.17
1 Malloc 3,91 MB 3,91 MB 1 1 7,83 MB 2 <XRRatioObject:
0x7ffd1c5dc3f0> %0.00, %0.00
And the inner allocations for each one:
First
# Address Category Timestamp Live Size Responsible Library
Responsible Caller
0 0x4d28000 CFString (store) 01:12.165.450 • 4923392 CFNetwork
_ZL19_cacheKeyForRequestPK13_CFURLRequest
1 0x36b8000 CFString (store) 00:54.705.461 • 172032 CFNetwork
_ZL19_cacheKeyForRequestPK13_CFURLRequest
2 0x1e3f5a00 CFString (store) 01:12.326.108 • 1024 CFNetwork
_ZL19_cacheKeyForRequestPK13_CFURLRequest
Second
# Address Category Timestamp Live Size Responsible Library
Responsible Caller
0 0x6903000 Malloc 3,91 MB 01:01.583.198 • 4104192 Foundation
-[NSConcreteMutableData initWithLength:]
Thanks!

No comments:

Post a Comment