Blame SOURCES/fix-resource-leak-InitSysContext.patch

a5f4ba
diff -ur tpm2.0-tools-1.1.0/src/syscontext.c tpm2.0-tools-1.1.0-new/src/syscontext.c
a5f4ba
--- tpm2.0-tools-1.1.0/src/syscontext.c	2016-11-04 07:13:32.000000000 -0700
a5f4ba
+++ tpm2.0-tools-1.1.0-new/src/syscontext.c	2017-04-04 22:46:07.365948473 -0700
a5f4ba
@@ -59,8 +59,10 @@
a5f4ba
 
a5f4ba
         if( rval == TSS2_RC_SUCCESS )
a5f4ba
             return sysContext;
a5f4ba
-        else
a5f4ba
+        else {
a5f4ba
+	    free(sysContext);
a5f4ba
             return 0;
a5f4ba
+	}
a5f4ba
     }
a5f4ba
     else
a5f4ba
     {