]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/acquire-item.cc
* mirror-failure.py: example mirror failure cgi
[apt.git] / apt-pkg / acquire-item.cc
index 421288007181fe408787f7ada7fcfe663bcaeb33..7b2a897638dd41170fade094411028bd34a25886 100644 (file)
@@ -176,7 +176,8 @@ string pkgAcqIndex::Custom600Headers()
    struct stat Buf;
    if (stat(Final.c_str(),&Buf) != 0)
       return "\nIndex-File: true";
    struct stat Buf;
    if (stat(Final.c_str(),&Buf) != 0)
       return "\nIndex-File: true";
-   
+   if(ExpectedMD5 != "")
+      return "\nExpectedMD5: " + ExpectedMD5;
    return "\nIndex-File: true\nLast-Modified: " + TimeRFC1123(Buf.st_mtime);
 }
                                                                        /*}}}*/
    return "\nIndex-File: true\nLast-Modified: " + TimeRFC1123(Buf.st_mtime);
 }
                                                                        /*}}}*/
@@ -637,7 +638,7 @@ bool pkgAcqMetaIndex::VerifyVendor(string Message)
    // check for missing sigs (that where not fatal because otherwise we had
    // bombed earlier)
    string missingkeys;
    // check for missing sigs (that where not fatal because otherwise we had
    // bombed earlier)
    string missingkeys;
-   string msg = _("There are no public key available for the "
+   string msg = _("There is no public key available for the "
                  "following key IDs:\n");
    pos = Message.find("NO_PUBKEY ");
    if (pos != std::string::npos)
                  "following key IDs:\n");
    pos = Message.find("NO_PUBKEY ");
    if (pos != std::string::npos)
@@ -1015,6 +1016,13 @@ void pkgAcqArchive::Failed(string Message,pkgAcquire::MethodConfig *Cnf)
    }
 }
                                                                        /*}}}*/
    }
 }
                                                                        /*}}}*/
+// ---------------------------------------------------------------------
+string pkgAcqArchive::Custom600Headers()
+{
+   if(MD5 != "")
+      return "\nExpectedMD5: " + MD5;
+   return "";
+}
 // AcqArchive::IsTrusted - Determine whether this archive comes from a
 // trusted source                                                      /*{{{*/
 // ---------------------------------------------------------------------
 // AcqArchive::IsTrusted - Determine whether this archive comes from a
 // trusted source                                                      /*{{{*/
 // ---------------------------------------------------------------------