Commit 4e62d26ff429816747bf75e8e3913338427557bc

Edward Thomson 2018-07-21T00:45:24

mbedtls: free ciphers_list

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
diff --git a/src/streams/mbedtls.c b/src/streams/mbedtls.c
index 5d88524..3e19c05 100644
--- a/src/streams/mbedtls.c
+++ b/src/streams/mbedtls.c
@@ -129,6 +129,7 @@ int git_mbedtls_stream_global_init(void)
 		goto cleanup;
 	}
 	mbedtls_ssl_conf_ciphersuites(git__ssl_conf, ciphers_list);
+	git__free(ciphers_list);
 
 	/* Seeding the random number generator */
 	mbedtls_entropy = git__malloc(sizeof(mbedtls_entropy_context));
@@ -166,6 +167,7 @@ cleanup:
 	mbedtls_ctr_drbg_free(ctr_drbg);
 	git__free(ctr_drbg);
 	mbedtls_ssl_config_free(git__ssl_conf);
+	git__free(ciphers_list);
 	git__free(git__ssl_conf);
 	git__ssl_conf = NULL;