diff options
author | gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3> | 2012-08-03 15:30:12 +0000 |
---|---|---|
committer | gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3> | 2012-08-03 15:30:12 +0000 |
commit | f11640235bd13697c96b50ca18d9d239b2cfbd11 (patch) | |
tree | e1a55778a7a1060f75240d4fb254c1c9c80219cd /Foundation/GTMServiceManagement.c | |
parent | 303bc8fbb608ff53352b4c66938761475126dd81 (diff) |
[Author: mmentovai]
Fix error-case memory leak in GTMSMJobRemove.
GTMPerformOnLabel will create an error in &local_error when it returns
NULL, so there is no need to create yet another error in local_error.
It masks the error created by GTMPerformOnLabel, which is leaked.
R=dmaclach,thomasvl
APPROVED=thomasvl
DELTA=2 (0 added, 2 deleted, 0 changed)
Diffstat (limited to 'Foundation/GTMServiceManagement.c')
-rw-r--r-- | Foundation/GTMServiceManagement.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/Foundation/GTMServiceManagement.c b/Foundation/GTMServiceManagement.c index 13bec32..efdc68e 100644 --- a/Foundation/GTMServiceManagement.c +++ b/Foundation/GTMServiceManagement.c @@ -663,8 +663,6 @@ Boolean GTMSMJobRemove(CFStringRef jobLabel, CFErrorRef *error) { break; } launch_data_free(resp); - } else { - local_error = GTMCFLaunchCreateUnlocalizedError(errno, CFSTR("")); } if (error) { *error = local_error; |