summaryrefslogtreecommitdiff
path: root/apt-pkg/contrib/strutl.h
AgeCommit message (Collapse)Author
2015-04-07demote VectorizeString gcc attribute from const to pureDavid Kalnischkies
g++-5 generates a slightly broken libapt which doesn't split architecture configurations correctly resulting in e.g. Packages files requested for the bogus architecture 'amd64,i386' instead of for amd64 and i386. The reason is an incorrectly applied attribute marking the function as const, while functions with pointer arguments are not allowed to be declared as such (note that char& is a char* in disguise). Demoting the attribute to pure fixes this issue – better would be dropping the & from char but that is an API change… Neither earlier g++ versions nor clang use this attribute to generate broken code, so we don't need a rebuild of dependencies or anything and g++-5 isn't even included in jessie, but the effect is so strange and apt popular enough to consider avoiding this problem anyhow.
2014-03-13follow method attribute suggestions by gccDavid Kalnischkies
Git-Dch: Ignore Reported-By: gcc -Wsuggest-attribute={pure,const,noreturn}
2014-03-13cleanup headers and especially #includes everywhereDavid Kalnischkies
Beside being a bit cleaner it hopefully also resolves oddball problems I have with high levels of parallel jobs. Git-Dch: Ignore Reported-By: iwyu (include-what-you-use)
2014-03-13warning: extra ‘;’ [-Wpedantic]David Kalnischkies
Git-Dch: Ignore Reported-By: gcc -Wpedantic
2013-11-29add "APT::String::Endswith" and automatic adding of ".list" in apt edit-sourceMichael Vogt
2013-10-18re-add missing APT::String::StripMichael Vogt
2013-10-01change maxsplit default from "0" to maxintMichael Vogt
2013-10-01improve documentation for StringSplit()Michael Vogt
2013-09-07doc updateMichael Vogt
2013-09-07add maxsplit parameter to StringSplitMichael Vogt
2013-09-07implement StringSplit() as we need this to fix the dpkg status-fd output parsingMichael Vogt
2013-08-12squash merge of the feature/apt-binary branch without the changes from ↵Michael Vogt
experimental
2013-03-15split out a method to strip whitespaces only on the right sideMichael Vogt
2011-12-13revert 2184.1.2: do not pollute namespace in headersDavid Kalnischkies
The breakage is just to big for now, so guard the change with #ifndef APT_8_CLEANER_HEADERS and be nice to library users
2011-09-19do not pollute namespace in the headers with using (Closes: #500198)David Kalnischkies
2011-09-13merge with debian/experimentalDavid Kalnischkies
2011-09-13Support large files in the complete toolset. Indexes of thisDavid Kalnischkies
size are pretty unlikely for now, but we need it for deb packages which could become bigger than 4GB now (LP: #815895)
2011-07-26fix typos in changelog, make DeEscapeString const, improve descriptionMichael Vogt
2011-07-26add another escape test case, fixup octal one (its \0XX instead of \0XXX)Michael Vogt
2011-07-26* apt-pkg/contrib/strutl.{h,cc}, test/libapt/strutil_test.cc:Michael Vogt
- add new DeEscapeString() similar to DeQuoteQuotedWord but unescape charackter escapes like \0XXX and \xXX (plus add test)
2011-02-03merge 'after squeeze release'-stuffDavid Kalnischkies
[ David Kalnischkies ] * apt-pkg/depcache.cc: - add SetCandidateRelease() to set a candidate version and the candidates of dependencies if needed to a specified release (Closes: #572709) * cmdline/apt-get.cc: - if --print-uris is used don't setup downloader as we don't need progress, lock nor the directories it would create otherwise - show dependencies of essential packages which are going to remove only if they cause the remove of this essential (Closes: #601961) - keep not installed garbage packages uninstalled instead of showing in the autoremove section and installing those (Closes: #604222) - change pkg/release behavior to use the new SetCandidateRelease so installing packages from experimental or backports is easier - really do not show packages in the extra section if they were requested on the commandline, e.g. with a modifier (Closes: #184730) * debian/control: - add Vcs-Browser now that loggerhead works again (Closes: #511168) - depend on debhelper 7 to raise compat level - depend on dpkg-dev (>= 1.15.8) to have c++ symbol mangling * apt-pkg/contrib/fileutl.cc: - add a RealFileExists method and check that your configuration files are real files to avoid endless loops if not (Closes: #604401) - ignore non-regular files in GetListOfFilesInDir (Closes: #594694) * apt-pkg/contrib/weakptr.h: - include stddefs.h to fix compile error (undefined NULL) with gcc-4.6 * methods/https.cc: - fix CURLOPT_SSL_VERIFYHOST by really passing 2 to it if enabled * deb/dpkgpm.cc: - fix popen/fclose mismatch reported by cppcheck. Thanks to Petter Reinholdtsen for report and patch! (Closes: #607803) * doc/apt.conf.5.xml: - fix multipl{y,e} spelling error reported by Jakub Wilk (Closes: #607636) * apt-inst/contrib/extracttar.cc: - let apt-utils work with encoded tar headers if uid/gid are large. Thanks to Nobuhiro Hayashi for the patch! (Closes: #330162) * apt-pkg/cacheiterator.h: - do not segfault if cache is not build (Closes: #254770) * doc/apt-get.8.xml: - remove duplicated mentioning of --install-recommends * doc/sources.list.5.xml: - remove obsolete references to non-us (Closes: #594495) * debian/rules: - use -- instead of deprecated -u for dh_gencontrol - remove shlibs.local creation and usage - show differences in the symbol files, but never fail * pre-build.sh: - remove as it is not needed for a working 'bzr bd' * debian/{apt,apt-utils}.symbols: - ship experimental unmangled c++ symbol files * methods/rred.cc: - operate optional on gzip compressed pdiffs * apt-pkg/acquire-item.cc: - don't uncompress downloaded pdiff files before feeding it to rred - try downloading clearsigned InRelease before trying Release.gpg - change the internal handling of Extensions in pkgAcqIndex - add a special uncompressed compression type to prefer those files - download and use i18n/Index to choose which Translations to download * cmdline/apt-key: - don't set trustdb-name as non-root so 'list' and 'finger' can be used without being root (Closes: #393005, #592107) * apt-pkg/deb/deblistparser.cc: - rewrite LoadReleaseInfo to cope with clearsigned Releasefiles * ftparchive/writer.cc: - add config option to search for more patterns in release command - include Index files by default in the Release file * methods/{gzip,bzip}.cc: - print a good error message if FileSize() is zero * apt-pkg/aptconfiguration.cc: - remove the inbuilt Translation files whitelist
2011-01-13* apt-inst/contrib/extracttar.cc:David Kalnischkies
- let apt-utils work with encoded tar headers if uid/gid are large. Thanks to Nobuhiro Hayashi for the patch! (Closes: #330162)
2010-12-03Permit base256 encoded value in the numeric field of tar header.Nobuhiro Hayashi
2010-11-16add support for third party changelogsMichael Vogt
2010-06-09move the users away from the deprecated StrToTime() methodDavid Kalnischkies
2010-06-08* apt-pkg/contrib/strutl.cc:David Kalnischkies
- split StrToTime() into HTTP1.1 and FTP date parser methods and use strptime() instead of some selfmade scanf mangling
2010-03-31Userinfo is urlencoded in URIs (RFC 3986)David Kalnischkies
Thanks to Jean-Baptiste Lallement for spotting and fixing it! * apt-pkg/contrib/strutl.cc: - always escape '%' (LP: #130289) (Closes: #500560) - unescape '%' sequence only if followed by 2 hex digit - username/password are urlencoded in proxy string (RFC 3986)
2010-03-30rename ExplodeString to VectorizeStringDavid Kalnischkies
2010-03-30replace every call to toupper with one to our own tolower_asciiDavid Kalnischkies
This sounds like a premature optimization and since Mr. Knuth we all know that they are the root of all evil - but, and here it starts to be interesting: As the tolower_ascii method is by far the most called method we have (~60 Mio. times) and as we compare only strings containing ascii characters (package names, configuration options) using our own method reduces execution time of APT by 4% plus it avoids that the locale settings can influence us.
2010-02-18merge from the lp:~donkult/apt/sid branchMichael Vogt
2010-02-18Change the package index Info methods to allow apt-cache policy to beMichael Vogt
useful when using several different archives on the same host. (Closes: #329814, LP: #22354)
2010-02-18dd support for the LANGUAGE environment variableDavid Kalnischkies
2009-10-24Avoid extra inner copy in APT_MKSTRCMP and APT_MKSTRCMP2David Kalnischkies
Backported from lp:~mvo/apt/debian-experimental Patch by Eugene V. Lyubimkin
2009-07-25Apply patch from Sami Liedes <sliedes@cc.hut.fi> to avoid unecessaryOtavio Salvador
temporary allocations.
2009-07-21* apt-pkg/acquire.cc:Michael Vogt
- make the max pipeline depth of the acquire queue configurable via Acquire::Max-Pipeline-Depth * apt-pkg/deb/dpkgpm.cc: - add Dpkg::UseIoNice boolean option to run dpkg with ionice -c3 (off by default) - send "dpkg-exec" message on the status fd when dpkg is run - provide DPkg::Chroot-Directory config option (useful for testing) - fix potential hang when in a backgroud process group * apt-pkg/algorithms.cc: - consider recommends when making the scores for the problem resolver * apt-pkg/acquire-worker.cc: - show error details of failed methods * apt-pkg/contrib/fileutl.cc: - if a process aborts with signal, show signal number * methods/http.cc: - ignore SIGPIPE, we deal with EPIPE from write in HttpMethod::ServerDie() (LP: #385144) * apt-pkg/indexcopy.cc: - support having CDs with no Packages file (just a Packages.gz) by not forcing a verification on non-existing files (LP: #255545) - remove the gettext from a string that consists entirely of variables (LP: #56792) * apt-pkg/cacheiterators.h: - add missing checks for Owner == 0 in end() * apt-pkg/indexrecords.cc: - fix some i18n issues * apt-pkg/contrib/strutl.h: - add new strprintf() function to make i18n strings easier - fix compiler warning * apt-pkg/deb/debsystem.cc: - make strings i18n able * fix problematic use of tolower() when calculating the version hash by using locale independant tolower_ascii() function. Thanks to M. Vefa Bicakci (LP: #80248) * build fixes for g++-4.4 * cmdline/apt-mark: - add "showauto" option to show automatically installed packages * document --install-recommends and --no-install-recommends (thanks to Dereck Wonnacott, LP: #126180) * Updated cron script to support backups by hardlinks and verbose levels. All features turned off by default. * Added more error handlings. Closes: #438803, #462734, #454989, * Refactored condition structure to make download and upgrade performed if only previous steps succeeded. Closes: #341970 * Documented all cron script related configuration items in configure-index. * apt-ftparchive might write corrupt Release files (LP: #46439) * Apply --important option to apt-cache depends (LP: #16947)
2009-06-29merge r1797 from lp:~donkult/apt/experimentalMichael Vogt
2009-04-23fix problematic use of tolower() when calculating the version Michael Vogt
hash by using locale independant tolower_ascii() function. Thanks to M. Vefa Bicakci (LP: #80248)
2008-12-08* apt-pkg/indexrecords.cc:Michael Vogt
- fix some i18n issues * apt-pkg/contrib/strutl.h: - add new strprintf() function to make i18n strings easier
2007-06-19* fixed compile errors with g++ 7.3 (thanks to Michael Vogt
Daniel Burrows, closes: #429378) * fix FTFBFS by changing build-depends to libcurl4-gnutls-dev (closes: #428363)
2006-12-14* merged the no-pragma branchMichael Vogt
2006-10-02* removed the pragma messMichael Vogt
2005-11-30* merged with apt--mvoMichael Vogt
Patches applied: * apt@packages.debian.org/apt--sources-list-d--0--base-0 tag of apt@packages.debian.org/apt--main--0--patch-30 * apt@packages.debian.org/apt--sources-list-d--0--patch-1 Patch from apt-rpm via Michael Vogt to implement /etc/apt/sources.list.d * bubulle@debian.org--2005/apt--main--0--patch-130 Galician translation completed * bubulle@debian.org--2005/apt--main--0--patch-131 Simplified Chinese translation update * bubulle@debian.org--2005/apt--main--0--patch-132 Completed Simplified Chinese translation * bubulle@debian.org--2005/apt--main--0--patch-133 Merge with Michael AND update PO files * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-90 * merged the sources.list.d patch * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-91 * merged with bubulle * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-92 * changelog update * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-93 * sources.list.d documented * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-94 * pkgDirStream has (slightly) better extract support now * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-95 * merge fix for #339533 * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-96 * merged with bubulle * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-97 * some more debug output * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-98 * ABI change: merged more flexible pkgAcquireFile code * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-99 * merged http download limit for apt (#146877) * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-100 * applied parts of the string speedup patch from debian #319377 (ABI change) * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-101 * fix for #340448 * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-102 * finalized this release * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-103 * changelog updates * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-104 * build-depend on libdb4.3 now, fix for kFreeBSD (#317718) * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-105 * fix mailaddress * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-106 * fix a string (thanks to bubulle) * michael.vogt@ubuntu.com--2005/apt--mvo--0--patch-107 * merged with bubulle
2005-11-23* applied parts of the string speedup patch from debian #319377 (ABI change)Michael Vogt
2005-03-23Port DDTP to APT 0.6 branchOtavio Salvador
2004-09-20Add safe_snprintfArch Librarian
Author: jgg Date: 2003-02-02 22:20:27 GMT Add safe_snprintf
2004-09-20Restored GCC 2.95 compilabilityArch Librarian
Author: jgg Date: 2001-05-29 05:09:44 GMT Restored GCC 2.95 compilability
2004-09-20Reverted CheckDomainList and LookupTag while adding new...Arch Librarian
Author: jgg Date: 2001-05-29 04:40:34 GMT Reverted CheckDomainList and LookupTag while adding new comparision functions for iterators
2004-09-20Changed comparision operatorsArch Librarian
Author: jgg Date: 2001-05-27 05:55:27 GMT Changed comparision operators
2004-09-20Ensure the memory buffer is 0'dArch Librarian
Author: jgg Date: 2001-05-27 05:19:30 GMT Ensure the memory buffer is 0'd
2004-09-20Alfredo's no_proxy patchArch Librarian
Author: jgg Date: 2001-02-23 05:45:27 GMT Alfredo's no_proxy patch