diff options
-rw-r--r-- | src/client/mac/handler/minidump_generator.cc | 9 | ||||
-rw-r--r-- | src/client/mac/sender/uploader.m | 1 |
2 files changed, 8 insertions, 2 deletions
diff --git a/src/client/mac/handler/minidump_generator.cc b/src/client/mac/handler/minidump_generator.cc index 68d7903a..1e4ea6b5 100644 --- a/src/client/mac/handler/minidump_generator.cc +++ b/src/client/mac/handler/minidump_generator.cc @@ -135,14 +135,19 @@ void MinidumpGenerator::GatherSystemInformation() { CFURLCreateDataAndPropertiesFromResource(NULL, sys_vers, &data, NULL, NULL, &error); - if (!data) + if (!data) { + CFRelease(sys_vers); return; + } CFDictionaryRef list = static_cast<CFDictionaryRef> (CFPropertyListCreateFromXMLData(NULL, data, kCFPropertyListImmutable, NULL)); - if (!list) + if (!list) { + CFRelease(sys_vers); + CFRelease(data); return; + } CFStringRef build_version = static_cast<CFStringRef> (CFDictionaryGetValue(list, CFSTR("ProductBuildVersion"))); diff --git a/src/client/mac/sender/uploader.m b/src/client/mac/sender/uploader.m index 4f34d4db..f215018e 100644 --- a/src/client/mac/sender/uploader.m +++ b/src/client/mac/sender/uploader.m @@ -475,6 +475,7 @@ NSString *const kDefaultServerType = @"google"; NSMutableDictionary *uploadParameters = [NSMutableDictionary dictionary]; if (![self populateServerDictionary:uploadParameters]) { + [upload release]; return; } |