aboutsummaryrefslogtreecommitdiff
path: root/crypto/http/http_lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/http/http_lib.c')
-rw-r--r--crypto/http/http_lib.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/crypto/http/http_lib.c b/crypto/http/http_lib.c
index fcf8a69e07a8..022b8c194cbe 100644
--- a/crypto/http/http_lib.c
+++ b/crypto/http/http_lib.c
@@ -263,6 +263,7 @@ static int use_proxy(const char *no_proxy, const char *server)
/* strip leading '[' and trailing ']' from escaped IPv6 address */
sl -= 2;
strncpy(host, server + 1, sl);
+ host[sl] = '\0';
server = host;
}