samvermette/SVGeocoder — Issue #15: Memory leak?
Author: cameroncooke
Created: 2012-01-20 12:42:09+00:00
State: open

Line 154 of SVGeocoder.m seems to be allocating an instance of `NSMutableURLRequest` (retain +1) and then setting the property self.request (retain +1) which means that self.request will never get released as it now has a retain count of +2.

Suggest adding autorelease:

```self.request = [[NSMutableURLRequest alloc] initWithURL:[NSURL URLWithString:@"http://maps.googleapis.com/maps/api/geocode/json"]];```

to

```self.request = [[[NSMutableURLRequest alloc] initWithURL:[NSURL URLWithString:@"http://maps.googleapis.com/maps/api/geocode/json"]] autorelease];```