|
|
ff3082 |
From 46b67e93a5458ef50eebfeb6a16e1df417274003 Mon Sep 17 00:00:00 2001
|
|
|
ff3082 |
From: Cathy Avery <cavery@redhat.com>
|
|
|
ff3082 |
Date: Sun, 25 Apr 2021 14:54:39 -0400
|
|
|
ff3082 |
Subject: [PATCH] Fix a memory leak reported by a partner from their Coverity
|
|
|
ff3082 |
scans.
|
|
|
ff3082 |
MIME-Version: 1.0
|
|
|
ff3082 |
Content-Type: text/plain; charset=UTF-8
|
|
|
ff3082 |
Content-Transfer-Encoding: 8bit
|
|
|
ff3082 |
|
|
|
ff3082 |
RH-Author: Cathy Avery (cavery)
|
|
|
ff3082 |
RH-MergeRequest: 3: Fix a memory leak reported by a partner from their Coverity scans.
|
|
|
ff3082 |
RH-Commit: [1/1] 31c94232c885c6d902cae33720a063ab0de401ce
|
|
|
ff3082 |
RH-Bugzilla: 1935807
|
|
|
ff3082 |
RH-Acked-by: Mohammed Gamal <mgamal@redhat.com>
|
|
|
ff3082 |
RH-Acked-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
|
|
ff3082 |
|
|
|
ff3082 |
commit 4f7441d8cd20923e509ff819084693bbd8c928df
|
|
|
ff3082 |
Author: John Wolfe <jwolfe@vmware.com>
|
|
|
ff3082 |
Date: Thu Mar 25 20:21:17 2021 -0700
|
|
|
ff3082 |
|
|
|
ff3082 |
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1935807
|
|
|
ff3082 |
Brew: https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=36406926
|
|
|
ff3082 |
Tested: Tested by QE
|
|
|
ff3082 |
Upstream Status: origin/devel
|
|
|
ff3082 |
Conflicts: None
|
|
|
ff3082 |
|
|
|
ff3082 |
Fix a memory leak reported by a partner from their Coverity scans.
|
|
|
ff3082 |
|
|
|
ff3082 |
Signed-off-by: Cathy Avery <cavery@redhat.com>
|
|
|
ff3082 |
---
|
|
|
ff3082 |
open-vm-tools/vgauth/serviceImpl/saml-xmlsec1.c | 8 +++-----
|
|
|
ff3082 |
1 file changed, 3 insertions(+), 5 deletions(-)
|
|
|
ff3082 |
|
|
|
ff3082 |
diff --git a/open-vm-tools/vgauth/serviceImpl/saml-xmlsec1.c b/open-vm-tools/vgauth/serviceImpl/saml-xmlsec1.c
|
|
|
ff3082 |
index fbadee2c..aaa5082a 100644
|
|
|
ff3082 |
--- a/open-vm-tools/vgauth/serviceImpl/saml-xmlsec1.c
|
|
|
ff3082 |
+++ b/open-vm-tools/vgauth/serviceImpl/saml-xmlsec1.c
|
|
|
ff3082 |
@@ -1,5 +1,5 @@
|
|
|
ff3082 |
/*********************************************************
|
|
|
ff3082 |
- * Copyright (C) 2016-2020 VMware, Inc. All rights reserved.
|
|
|
ff3082 |
+ * Copyright (C) 2016-2021 VMware, Inc. All rights reserved.
|
|
|
ff3082 |
*
|
|
|
ff3082 |
* This program is free software; you can redistribute it and/or modify it
|
|
|
ff3082 |
* under the terms of the GNU Lesser General Public License as published
|
|
|
ff3082 |
@@ -872,7 +872,6 @@ VerifySubject(xmlDocPtr doc,
|
|
|
ff3082 |
xmlNodePtr nameIDNode;
|
|
|
ff3082 |
xmlNodePtr child;
|
|
|
ff3082 |
gchar *subjectVal = NULL;
|
|
|
ff3082 |
- gboolean retCode = FALSE;
|
|
|
ff3082 |
gboolean validSubjectFound = FALSE;
|
|
|
ff3082 |
xmlChar *tmp;
|
|
|
ff3082 |
|
|
|
ff3082 |
@@ -956,14 +955,13 @@ VerifySubject(xmlDocPtr doc,
|
|
|
ff3082 |
}
|
|
|
ff3082 |
}
|
|
|
ff3082 |
|
|
|
ff3082 |
+done:
|
|
|
ff3082 |
if (validSubjectFound && (NULL != subjectRet)) {
|
|
|
ff3082 |
*subjectRet = subjectVal;
|
|
|
ff3082 |
} else {
|
|
|
ff3082 |
g_free(subjectVal);
|
|
|
ff3082 |
}
|
|
|
ff3082 |
- retCode = validSubjectFound;
|
|
|
ff3082 |
-done:
|
|
|
ff3082 |
- return retCode;
|
|
|
ff3082 |
+ return validSubjectFound;
|
|
|
ff3082 |
}
|
|
|
ff3082 |
|
|
|
ff3082 |
|
|
|
ff3082 |
--
|
|
|
ff3082 |
2.27.0
|
|
|
ff3082 |
|