From 4e49cc49f8e514828eec8780130d09289bdc061c Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Sat, 17 Jan 2026 05:39:02 +0500 Subject: [PATCH] engine: common: http: optimistically treat https as http as a temporary hack --- engine/common/http/net_http_xash.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/engine/common/http/net_http_xash.c b/engine/common/http/net_http_xash.c index ff6fd41b..d0d64f6e 100644 --- a/engine/common/http/net_http_xash.c +++ b/engine/common/http/net_http_xash.c @@ -994,12 +994,22 @@ static void HTTP_Download_f( void ) HTTP_ParseURL ============== */ -static httpserver_t *HTTP_ParseURL( const char *url ) +static httpserver_t *HTTP_ParseURL( const char *url_ ) { httpserver_t *server; int i; + const char *url = NULL; - url = Q_strstr( url, "http://" ); + url = Q_strstr( url_, "http://" ); + + if( url ) + url += 7; + else + { + url = Q_strstr( url_, "https://" ); + if( url ) + url += 8; + } if( !url ) return NULL;