Michael Vogt лет назад: 11
Родитель
Сommit
916b89109c
2 измененных файлов с 8 добавлено и 9 удалено
  1. 5 5
      apt-pkg/acquire-item.cc
  2. 3 4
      apt-pkg/acquire-item.h

+ 5 - 5
apt-pkg/acquire-item.cc

@@ -850,7 +850,7 @@ void pkgAcqIndexMergeDiffs::Done(string Message,unsigned long long Size,HashStri
    instantiated to fetch the revision file */   
    instantiated to fetch the revision file */   
 pkgAcqIndex::pkgAcqIndex(pkgAcquire *Owner,
 pkgAcqIndex::pkgAcqIndex(pkgAcquire *Owner,
 			 string URI,string URIDesc,string ShortDesc,
 			 string URI,string URIDesc,string ShortDesc,
-			 HashStringList const  &ExpectedHash, string comprExt)
+			 HashStringList const  &ExpectedHash)
    : pkgAcqBaseIndex(Owner, 0, NULL, ExpectedHash, NULL), RealURI(URI)
    : pkgAcqBaseIndex(Owner, 0, NULL, ExpectedHash, NULL), RealURI(URI)
 {
 {
    AutoSelectCompression();
    AutoSelectCompression();
@@ -1035,7 +1035,7 @@ std::string pkgAcqIndex::GetFinalFilename(std::string const &URI,
 // AcqIndex::ReverifyAfterIMS - Reverify index after an ims-hit        /*{{{*/
 // AcqIndex::ReverifyAfterIMS - Reverify index after an ims-hit        /*{{{*/
 // ---------------------------------------------------------------------
 // ---------------------------------------------------------------------
 /* */
 /* */
-void pkgAcqIndex::ReverifyAfterIMS(std::string const &FileName)
+void pkgAcqIndex::ReverifyAfterIMS()
 {
 {
    std::string const compExt = CompressionExtension.substr(0, CompressionExtension.find(' '));
    std::string const compExt = CompressionExtension.substr(0, CompressionExtension.find(' '));
    if (_config->FindB("Acquire::GzipIndexes",false) && compExt == "gz")
    if (_config->FindB("Acquire::GzipIndexes",false) && compExt == "gz")
@@ -1132,7 +1132,7 @@ void pkgAcqIndex::Done(string Message,unsigned long long Size,HashStringList con
       // The files timestamp matches
       // The files timestamp matches
       if (StringToBool(LookupTag(Message,"Alt-IMS-Hit"),false) == true)
       if (StringToBool(LookupTag(Message,"Alt-IMS-Hit"),false) == true)
       {
       {
-         ReverifyAfterIMS(FileName);
+         ReverifyAfterIMS();
 	 return;
 	 return;
       }
       }
       Decompression = true;
       Decompression = true;
@@ -1154,7 +1154,7 @@ void pkgAcqIndex::Done(string Message,unsigned long long Size,HashStringList con
    // The files timestamp matches
    // The files timestamp matches
    if (StringToBool(LookupTag(Message,"IMS-Hit"),false) == true)
    if (StringToBool(LookupTag(Message,"IMS-Hit"),false) == true)
    {
    {
-      ReverifyAfterIMS(FileName);
+      ReverifyAfterIMS();
       return;
       return;
     }
     }
 
 
@@ -1197,7 +1197,7 @@ void pkgAcqIndex::Done(string Message,unsigned long long Size,HashStringList con
 /* The Translation file is added to the queue */
 /* The Translation file is added to the queue */
 pkgAcqIndexTrans::pkgAcqIndexTrans(pkgAcquire *Owner,
 pkgAcqIndexTrans::pkgAcqIndexTrans(pkgAcquire *Owner,
 			    string URI,string URIDesc,string ShortDesc) 
 			    string URI,string URIDesc,string ShortDesc) 
-  : pkgAcqIndex(Owner, URI, URIDesc, ShortDesc, HashStringList(), "")
+  : pkgAcqIndex(Owner, URI, URIDesc, ShortDesc, HashStringList())
 {
 {
 }
 }
 									/*}}}*/
 									/*}}}*/

+ 3 - 4
apt-pkg/acquire-item.h

@@ -353,7 +353,7 @@ class pkgAcqMetaBase  : public pkgAcquire::Item
    // transaction code
    // transaction code
    void Add(Item *I);
    void Add(Item *I);
    void AbortTransaction();
    void AbortTransaction();
-   bool TransactionHasError();
+   bool TransactionHasError() APT_PURE;
    void CommitTransaction();
    void CommitTransaction();
 
 
    // helper for the signature warning
    // helper for the signature warning
@@ -885,7 +885,7 @@ class pkgAcqIndex : public pkgAcqBaseIndex
                                 std::string const &compExt);
                                 std::string const &compExt);
 
 
    /** \brief Schedule file for verification after a IMS hit */
    /** \brief Schedule file for verification after a IMS hit */
-   void ReverifyAfterIMS(std::string const &FileName);
+   void ReverifyAfterIMS();
 
 
    public:
    public:
    
    
@@ -916,8 +916,7 @@ class pkgAcqIndex : public pkgAcqBaseIndex
     *  fallback is ".gz" or none.
     *  fallback is ".gz" or none.
     */
     */
    pkgAcqIndex(pkgAcquire *Owner,std::string URI,std::string URIDesc,
    pkgAcqIndex(pkgAcquire *Owner,std::string URI,std::string URIDesc,
-	       std::string ShortDesc, HashStringList const &ExpectedHashes,
-	       std::string compressExt="");
+	       std::string ShortDesc, HashStringList const &ExpectedHashes);
    pkgAcqIndex(pkgAcquire *Owner, pkgAcqMetaBase *TransactionManager,
    pkgAcqIndex(pkgAcquire *Owner, pkgAcqMetaBase *TransactionManager,
                IndexTarget const * const Target,
                IndexTarget const * const Target,
                HashStringList const &ExpectedHash,
                HashStringList const &ExpectedHash,