X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/b84fa7158d04f8b2136f01dda106ba0272027887..6612c86ef3d8f2b8bccc6212791996ab9e053082:/methods/https.h diff --git a/methods/https.h b/methods/https.h index 2c33d95ee..293e288e0 100644 --- a/methods/https.h +++ b/methods/https.h @@ -8,10 +8,8 @@ ##################################################################### */ /*}}}*/ -#ifndef APT_HTTP_H -#define APT_HTTP_H - -#define MAXLEN 360 +#ifndef APT_HTTPS_H +#define APT_HTTPS_H #include #include @@ -20,10 +18,12 @@ using std::cout; using std::endl; class HttpsMethod; - +class FileFd; class HttpsMethod : public pkgAcqMethod { + // minimum speed in bytes/se that triggers download timeout handling + static const int DL_MIN_SPEED = 10; virtual bool Fetch(FetchItem *); static size_t write_data(void *buffer, size_t size, size_t nmemb, void *userp); @@ -41,8 +41,14 @@ class HttpsMethod : public pkgAcqMethod File = 0; curl = curl_easy_init(); }; + + ~HttpsMethod() + { + curl_easy_cleanup(curl); + }; }; +#include URI Proxy; #endif