From: VMware, Inc <> Date: Thu, 17 Jun 2010 21:56:27 +0000 (-0700) Subject: Fix a couple of gsource handle leaks in the vmbackup plugin. X-Git-Tag: 2010.06.16-268169~77 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aaa1a7d277c30852dd42f79b87e17e9c429caec9;p=thirdparty%2Fopen-vm-tools.git Fix a couple of gsource handle leaks in the vmbackup plugin. Signed-off-by: Marcelo Vanzin --- diff --git a/open-vm-tools/services/plugins/vmbackup/stateMachine.c b/open-vm-tools/services/plugins/vmbackup/stateMachine.c index b44c168ef..45fb4012a 100644 --- a/open-vm-tools/services/plugins/vmbackup/stateMachine.c +++ b/open-vm-tools/services/plugins/vmbackup/stateMachine.c @@ -152,6 +152,7 @@ VmBackup_SendEvent(const char *event, g_debug("*** %s\n", __FUNCTION__); if (gBackupState->keepAlive != NULL) { g_source_destroy(gBackupState->keepAlive); + g_source_unref(gBackupState->keepAlive); } msg = g_strdup_printf(VMBACKUP_PROTOCOL_EVENT_SET" %s %u %s", event, code, desc); @@ -195,10 +196,12 @@ VmBackupFinalize(void) if (gBackupState->timerEvent != NULL) { g_source_destroy(gBackupState->timerEvent); + g_source_unref(gBackupState->timerEvent); } if (gBackupState->keepAlive != NULL) { g_source_destroy(gBackupState->keepAlive); + g_source_unref(gBackupState->keepAlive); } gBackupState->provider->release(gBackupState->provider);