Fix memleak

This commit is contained in:
Quentin Dufour 2019-03-27 17:37:34 +01:00
parent b6258759f0
commit da6815ec62

View file

@ -38,7 +38,7 @@ void socks5_create_dns_client(struct evt_core_ctx* ctx, char* proxy_host, char*
memset(fdinfo.other, 0, sizeof(struct socks5_ctx));
fdinfo.free_other = socks5_free_ctx;
sprintf(url, "socks5:send-hs:%s:%d", addr, port);
fdinfo.url = strdup(url);
fdinfo.url = url;
// 3. Fill socks5_ctx structures
s5ctx = fdinfo.other;