Merge pull request #61 from Zentyal/ejhernandez/memory-leaks

Fix memory leak on getPidTagSubject
This commit is contained in:
Kamen Mazdrashki
2014-11-30 00:58:01 +01:00
2 changed files with 3 additions and 3 deletions
+3 -1
View File
@@ -795,7 +795,7 @@ rtf2html (NSData *compressedRTF)
TALLOC_CTX *localMemCtx;
char *prefix, *normalizedSubject;
localMemCtx = talloc_zero (NULL, TALLOC_CTX);
localMemCtx = talloc_zero (memCtx, TALLOC_CTX);
if ([self getProperty: (void **) &prefix
withTag: PidTagSubjectPrefix
inMemCtx: localMemCtx]
@@ -807,6 +807,8 @@ rtf2html (NSData *compressedRTF)
if (rc == MAPISTORE_SUCCESS)
*data = talloc_asprintf (memCtx, "%s%s", prefix, normalizedSubject);
talloc_free(localMemCtx);
return rc;
}
-2
View File
@@ -55,8 +55,6 @@ static NSArray *privilegedTagNames = nil;
- (void) dealloc
{
if (content)
free (content);
[self reset];
[cards release];
[currentGroup release];