#include <string>
#include <stdio.h>
#include <sys/types.h>
-
+#include <time.h>
+
class MultiCompress
{
// An output file
FileFd TmpFile;
pid_t CompressProc;
time_t OldMTime;
- int Fd;
};
Files *Outputs;
pid_t Outputter;
mode_t Permissions;
- bool OpenCompress(APT::Configuration::Compressor const &Prog,
- pid_t &Pid,int const &FileFd, int &OutFd,bool const &Comp);
bool Child(int const &Fd);
bool Start();
bool Die();
public:
// The FD to write to for compression.
- FILE *Input;
+ FileFd Input;
unsigned long UpdateMTime;
bool Finalize(unsigned long long &OutSize);
- bool OpenOld(int &Fd,pid_t &Proc);
- bool CloseOld(int Fd,pid_t Proc);
+ bool OpenOld(FileFd &Fd);
static bool GetStat(std::string const &Output,std::string const &Compress,struct stat &St);
MultiCompress(std::string const &Output,std::string const &Compress,