]> git.saurik.com Git - apt.git/blobdiff - methods/https.cc
Send "Fail-Reason: MaximumSizeExceeded" from the method
[apt.git] / methods / https.cc
index 787e4a5075a99aaf180935f6380fab83fe5a63de..16d564b34d79acc9608889cb7206850881bb42b4 100644 (file)
@@ -83,9 +83,11 @@ HttpsMethod::write_data(void *buffer, size_t size, size_t nmemb, void *userp)
       return false;
 
    if(me->Queue->MaximumSize > 0 && me->File->Tell() > me->Queue->MaximumSize)
+   {
+      me->SetFailReason("MaximumSizeExceeded");
       return _error->Error("Writing more data than expected (%llu > %llu)",
                            me->TotalWritten, me->Queue->MaximumSize);
-
+   }
    return size*nmemb;
 }