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