krb5 commit: Fix small leak in wshelper DLL

Greg Hudson ghudson at mit.edu
Mon Apr 9 19:46:20 EDT 2018


https://github.com/krb5/krb5/commit/0c013d6bc018d5be9f694ce80a27de740628133d
commit 0c013d6bc018d5be9f694ce80a27de740628133d
Author: Greg Hudson <ghudson at mit.edu>
Date:   Mon Apr 9 11:00:05 2018 -0400

    Fix small leak in wshelper DLL
    
    Remove a double initialization of dwHesPwUidIndex in wshelper which
    caused the first initialization to leak a thread-local storage handle.
    Reported by Sergey Ilinykh.
    
    ticket: 8663

 src/util/wshelper/dllmain.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/src/util/wshelper/dllmain.c b/src/util/wshelper/dllmain.c
index 5ae0016..d3706d2 100644
--- a/src/util/wshelper/dllmain.c
+++ b/src/util/wshelper/dllmain.c
@@ -43,8 +43,6 @@ DllMain(
             return FALSE;
 	if ((dwHesPwUidIndex = TlsAlloc()) == TLS_OUT_OF_INDEXES)
             return FALSE;
-	if ((dwHesPwUidIndex = TlsAlloc()) == TLS_OUT_OF_INDEXES)
-            return FALSE;
 	if ((dwGhnIndex = TlsAlloc()) == TLS_OUT_OF_INDEXES)
             return FALSE;
 	if ((dwGhaIndex = TlsAlloc()) == TLS_OUT_OF_INDEXES)


More information about the cvs-krb5 mailing list