From 7365ff46a3852e2d3abd2cfdfcfad37ac362c427 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 3 Oct 2008 20:15:06 +0200 Subject: Fix some typos in docs and translations (thanks to timeless, closes: 368665) --- apt-pkg/contrib/cmndline.h | 2 +- apt-pkg/contrib/strutl.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'apt-pkg/contrib') diff --git a/apt-pkg/contrib/cmndline.h b/apt-pkg/contrib/cmndline.h index fad6d1da9..e28071e81 100644 --- a/apt-pkg/contrib/cmndline.h +++ b/apt-pkg/contrib/cmndline.h @@ -34,7 +34,7 @@ ConfigFile - Means this flag should be interprited as the name of a config file to read in at this point in option processing. Implies HasArg. - ArbItem - Means the item is an arbitary configuration string of + ArbItem - Means the item is an arbitrary configuration string of the form item=value, where item is passed directly to the configuration class. The default, if the flags are 0 is to use Boolean diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc index eacc7077a..3a0abc5a8 100644 --- a/apt-pkg/contrib/strutl.cc +++ b/apt-pkg/contrib/strutl.cc @@ -461,7 +461,7 @@ string Base64Encode(const string &S) /*}}}*/ // stringcmp - Arbitary string compare /*{{{*/ // --------------------------------------------------------------------- -/* This safely compares two non-null terminated strings of arbitary +/* This safely compares two non-null terminated strings of arbitrary length */ int stringcmp(const char *A,const char *AEnd,const char *B,const char *BEnd) { -- cgit v1.2.3 From 0da8987ab9e67ad693e38bb5cfe692f12b1a7db9 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 3 Oct 2008 20:57:25 +0200 Subject: Applying #298821 patch for further arbitary typos --- apt-pkg/contrib/cmndline.cc | 2 +- apt-pkg/contrib/strutl.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'apt-pkg/contrib') diff --git a/apt-pkg/contrib/cmndline.cc b/apt-pkg/contrib/cmndline.cc index 54c91d67d..bfd53695e 100644 --- a/apt-pkg/contrib/cmndline.cc +++ b/apt-pkg/contrib/cmndline.cc @@ -189,7 +189,7 @@ bool CommandLine::HandleOpt(int &I,int argc,const char *argv[], if ((A->Flags & ConfigFile) == ConfigFile) return ReadConfigFile(*Conf,Argument); - // Arbitary item specification + // Arbitrary item specification if ((A->Flags & ArbItem) == ArbItem) { const char *J; diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc index 3a0abc5a8..bd374fd1e 100644 --- a/apt-pkg/contrib/strutl.cc +++ b/apt-pkg/contrib/strutl.cc @@ -459,7 +459,7 @@ string Base64Encode(const string &S) return Final; } /*}}}*/ -// stringcmp - Arbitary string compare /*{{{*/ +// stringcmp - Arbitrary string compare /*{{{*/ // --------------------------------------------------------------------- /* This safely compares two non-null terminated strings of arbitrary length */ @@ -517,7 +517,7 @@ int stringcmp(string::const_iterator A,string::const_iterator AEnd, } #endif /*}}}*/ -// stringcasecmp - Arbitary case insensitive string compare /*{{{*/ +// stringcasecmp - Arbitrary case insensitive string compare /*{{{*/ // --------------------------------------------------------------------- /* */ int stringcasecmp(const char *A,const char *AEnd,const char *B,const char *BEnd) -- cgit v1.2.3 From 3c8cda8b05d6eeaef76c7ccc673fe378b0c74f37 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 28 Oct 2008 18:14:29 +0100 Subject: fix various -Wall warnings --- apt-pkg/contrib/cdromutl.cc | 3 ++- apt-pkg/contrib/mmap.cc | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'apt-pkg/contrib') diff --git a/apt-pkg/contrib/cdromutl.cc b/apt-pkg/contrib/cdromutl.cc index 6f00e1451..b6524a178 100644 --- a/apt-pkg/contrib/cdromutl.cc +++ b/apt-pkg/contrib/cdromutl.cc @@ -176,7 +176,8 @@ bool IdentCdrom(string CD,string &Res,unsigned int Version) Hash.Add(Dir->d_name); }; - chdir(StartDir.c_str()); + if (chdir(StartDir.c_str()) != 0) + return _error->Errno("chdir",_("Unable to change to %s"),StartDir.c_str()); closedir(D); // Some stats from the fsys diff --git a/apt-pkg/contrib/mmap.cc b/apt-pkg/contrib/mmap.cc index abcae46fe..eed438250 100644 --- a/apt-pkg/contrib/mmap.cc +++ b/apt-pkg/contrib/mmap.cc @@ -192,7 +192,8 @@ DynamicMMap::~DynamicMMap() unsigned long EndOfFile = iSize; iSize = WorkSpace; Close(false); - ftruncate(Fd->Fd(),EndOfFile); + if(ftruncate(Fd->Fd(),EndOfFile) < 0) + _error->Errno("ftruncate", _("Failed to truncate file")); } /*}}}*/ // DynamicMMap::RawAllocate - Allocate a raw chunk of unaligned space /*{{{*/ @@ -209,7 +210,7 @@ unsigned long DynamicMMap::RawAllocate(unsigned long Size,unsigned long Aln) // Just in case error check if (Result + Size > WorkSpace) { - _error->Error("Dynamic MMap ran out of room"); + _error->Error(_("Dynamic MMap ran out of room")); return 0; } -- cgit v1.2.3