Browse Source

Initialize hostend to avoid false warning

bel 9 years ago
parent
commit
3212e78e54
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/civetweb.c

+ 2 - 1
src/civetweb.c

@@ -9981,7 +9981,8 @@ get_rel_url_at_current_server(const char *uri, const struct mg_connection *conn)
 	size_t domain_len;
 	unsigned long port = 0;
 	int i;
-	char *hostend, *portbegin, *portend;
+	char *hostend = NULL;
+    char *portbegin, *portend;
 
 	/* DNS is case insensitive, so use case insensitive string compare here */
 	domain = conn->ctx->config[AUTHENTICATION_DOMAIN];