uclient-fetch: init_ca_cert: fix memory leak
[project/uclient.git] / uclient-fetch.c
index 1c66ac6..bbf5eec 100644 (file)
@@ -503,6 +503,7 @@ static void init_ca_cert(void)
        glob("/etc/ssl/certs/*.crt", 0, NULL, &gl);
        for (i = 0; i < gl.gl_pathc; i++)
                ssl_ops->context_add_ca_crt_file(ssl_ctx, gl.gl_pathv[i]);
+       globfree(&gl);
 }
 
 static void init_ustream_ssl(void)