]> git.saurik.com Git - apt.git/blobdiff - methods/rred.cc
enable FileFd to guess the compressor based on the filename if requested or
[apt.git] / methods / rred.cc
index 2a05acce1f8275536277712a4e22b4b502feb25c..56ad8220b8006e5ff2d4cd33140bb3064d794ff0 100644 (file)
@@ -7,6 +7,7 @@
 #include <apt-pkg/acquire-method.h>
 #include <apt-pkg/strutl.h>
 #include <apt-pkg/hashes.h>
+#include <apt-pkg/configuration.h>
 
 #include <sys/stat.h>
 #include <sys/uio.h>
@@ -488,7 +489,7 @@ bool RredMethod::Fetch(FetchItem *Itm)                                              /*{{{*/
    // Open the source and destination files (the d'tor of FileFd will do 
    // the cleanup/closing of the fds)
    FileFd From(Path,FileFd::ReadOnly);
-   FileFd Patch(Path+".ed",FileFd::ReadOnlyGzip);
+   FileFd Patch(Path+".ed",FileFd::ReadOnly, FileFd::Gzip);
    FileFd To(Itm->DestFile,FileFd::WriteAtomic);   
    To.EraseOnFailure();
    if (_error->PendingError() == true)