]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - libcurl.c
CSQC entity sending rework.
[xonotic/darkplaces.git] / libcurl.c
index 2d95afbb0f590e625281e2f36a4fb1b2fc0cbda1..48b9fdaa6e07ed1065590ebe47a39416082b3832 100644 (file)
--- a/libcurl.c
+++ b/libcurl.c
@@ -878,7 +878,7 @@ static qboolean Curl_Begin(const char *URL, const char *extraheaders, double max
                if(loadtype != LOADTYPE_NONE)
                        Host_Error("Curl_Begin: loadtype and buffer are both set");
 
-       if(!curl_dll)
+       if(!curl_dll || !cl_curl_enabled.integer)
        {
                return false;
        }
@@ -1226,7 +1226,7 @@ void Curl_Run(void)
        if(maxspeed > 0)
        {
                double bytes = bytes_sent + bytes_received; // maybe smoothen a bit?
-               curltime = realtime + bytes / (cl_curl_maxspeed.value * 1024.0);
+               curltime = realtime + bytes / (maxspeed * 1024.0);
                bytes_sent = 0;
                bytes_received = 0;
        }