From 9209ec4701d9f6c21d4ae9ebb648d94a1f32665a Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Sat, 28 Nov 2009 03:19:52 +0100 Subject: tell every method in ftparchive/ that const& is sexy --- ftparchive/multicompress.cc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'ftparchive/multicompress.cc') diff --git a/ftparchive/multicompress.cc b/ftparchive/multicompress.cc index 2fc8efcbf..7c91d34fe 100644 --- a/ftparchive/multicompress.cc +++ b/ftparchive/multicompress.cc @@ -40,14 +40,14 @@ const MultiCompress::CompType MultiCompress::Compressors[] = // MultiCompress::MultiCompress - Constructor /*{{{*/ // --------------------------------------------------------------------- /* Setup the file outputs, compression modes and fork the writer child */ -MultiCompress::MultiCompress(string Output,string Compress, - mode_t Permissions,bool Write) +MultiCompress::MultiCompress(string const &Output,string const &Compress, + mode_t const &Permissions,bool const &Write) : + Permissions(Permissions) { Outputs = 0; Outputter = -1; Input = 0; UpdateMTime = 0; - this->Permissions = Permissions; /* Parse the compression string, a space separated lists of compresison types */ @@ -126,7 +126,7 @@ MultiCompress::~MultiCompress() /* This checks each compressed file to make sure it exists and returns stat information for a random file from the collection. False means one or more of the files is missing. */ -bool MultiCompress::GetStat(string Output,string Compress,struct stat &St) +bool MultiCompress::GetStat(string const &Output,string const &Compress,struct stat &St) { /* Parse the compression string, a space separated lists of compresison types */ @@ -268,8 +268,8 @@ bool MultiCompress::Finalize(unsigned long &OutSize) /* This opens the compressor, either in compress mode or decompress mode. FileFd is always the compressor input/output file, OutFd is the created pipe, Input for Compress, Output for Decompress. */ -bool MultiCompress::OpenCompress(const CompType *Prog,pid_t &Pid,int FileFd, - int &OutFd,bool Comp) +bool MultiCompress::OpenCompress(const CompType *Prog,pid_t &Pid,int const &FileFd, + int &OutFd,bool const &Comp) { Pid = -1; @@ -369,7 +369,7 @@ bool MultiCompress::CloseOld(int Fd,pid_t Proc) computes the MD5 of the raw data. After this the raw data in the original files is compared to see if this data is new. If the data is new then the temp files are renamed, otherwise they are erased. */ -bool MultiCompress::Child(int FD) +bool MultiCompress::Child(int const &FD) { // Start the compression children. for (Files *I = Outputs; I != 0; I = I->Next) -- cgit v1.2.3 From c6474fb6ff482b0457674986a82afab0a3749af2 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Tue, 1 Dec 2009 00:28:26 +0100 Subject: fix a few typos in strings, comments and manpage of apt-ftparchive thanks Karl Goetz! (Closes: #558757) --- ftparchive/multicompress.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ftparchive/multicompress.cc') diff --git a/ftparchive/multicompress.cc b/ftparchive/multicompress.cc index 7c91d34fe..bb4beedf9 100644 --- a/ftparchive/multicompress.cc +++ b/ftparchive/multicompress.cc @@ -365,7 +365,7 @@ bool MultiCompress::CloseOld(int Fd,pid_t Proc) // MultiCompress::Child - The writer child /*{{{*/ // --------------------------------------------------------------------- /* The child process forks a bunch of compression children and takes - input on FD and passes it to all the compressor childer. On the way it + input on FD and passes it to all the compressor child. On the way it computes the MD5 of the raw data. After this the raw data in the original files is compared to see if this data is new. If the data is new then the temp files are renamed, otherwise they are erased. */ -- cgit v1.2.3