clean new canl_cred struct.
authorMarcel Poul <marcel.poul@cern.ch>
Wed, 18 Jan 2012 12:28:34 +0000 (12:28 +0000)
committerMarcel Poul <marcel.poul@cern.ch>
Wed, 18 Jan 2012 12:28:34 +0000 (12:28 +0000)
emi.canl.canl-c/src/canl_cred.c

index 97529cf..5e29314 100644 (file)
@@ -52,6 +52,10 @@ canl_cred_free(canl_ctx ctx, canl_cred cred)
         sk_X509_pop_free(crd->c_cert_chain, X509_free);
         crd->c_cert_chain = NULL;
     }
+    if (crd->c_req) {
+        X509_REQ_free(crd->c_req);
+        crd->c_req = NULL;
+    }
 
     free (crd);
     crd = NULL;