summaryrefslogtreecommitdiff
path: root/apt-pkg/contrib/error.cc
Commit message (Collapse)AuthorAgeFilesLines
* Modernize standard library includesJulian Andres Klode2024-02-201-5/+5
| | | | | | This was automated with sed and git-clang-format, and then I had to fix up the top of policy.cc by hand as git-clang-format accidentally indented it by two spaces.
* Address statements of public domainJulian Andres Klode2023-03-061-0/+4
|
* Add color highlighting to E:/W:/N: prefixesJulian Andres Klode2020-03-241-0/+46
| | | | | | This matches the definitions used by dpkg. Closes: #953527
* error: Extract operator<< into error.cc (de-inline it)Julian Andres Klode2020-03-101-0/+42
| | | | | Extract the code, and reformat it with clang-format so we can modify it.
* Fix memory leak in C++-thread-local _error implementationJulian Andres Klode2017-07-201-2/+2
| | | | | | | We can't allocate a pointer here, it would not get released - use an object instead. Gbp-Dch: ignore
* Use C++11 threading support instead of pthreadJulian Andres Klode2017-07-201-25/+3
| | | | This makes the code easier to read.
* Reformat and sort all includes with clang-formatJulian Andres Klode2017-07-121-17/+18
| | | | | | | | | | | | | This makes it easier to see which headers includes what. The changes were done by running git grep -l '#\s*include' \ | grep -E '.(cc|h)$' \ | xargs sed -i -E 's/(^\s*)#(\s*)include/\1#\2 include/' To modify all include lines by adding a space, and then running ./git-clang-format.sh.
* (error) va_list 'args' was opened but not closed by va_end()David Kalnischkies2016-07-271-18/+16
| | | | | Reported-By: cppcheck Gbp-Dch: Ignore
* avoid using global PendingError to avoid failing too often too soonDavid Kalnischkies2015-09-141-15/+13
| | | | | | | | | | | | | | | | | | | Our error reporting is historically grown into some kind of mess. A while ago I implemented stacking for the global error which is used in this commit now to wrap calls to functions which do not report (all) errors via return, so that only failures in those calls cause a failure to propergate down the chain rather than failing if anything (potentially totally unrelated) has failed at some point in the past. This way we can avoid stopping the entire acquire process just because a single source produced an error for example. It also means that after the acquire process the cache is generated – even if the acquire process had failures – as we still have the old good data around we can and should generate a cache for (again). There are probably more instances of this hiding, but all these looked like the easiest to work with and fix with reasonable (aka net-positive) effects.
* cleanup headers and especially #includes everywhereDavid Kalnischkies2014-03-131-1/+3
| | | | | | | | 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)
* warning: extra ‘;’ [-Wpedantic]David Kalnischkies2014-03-131-1/+1
| | | | | Git-Dch: Ignore Reported-By: gcc -Wpedantic
* proper cleanup varargs in _error (uncovered by Coverity)David Kalnischkies2013-07-261-4/+6
| | | | Git-Dch: Ignore
* merge with debian/experimentalDavid Kalnischkies2011-09-131-3/+3
|\
| * cppcheck complains about some possible speed improvements which could beDavid Kalnischkies2011-08-111-3/+3
| | | | | | | | | | | | done on the mirco-optimazation level, so lets fix them: (performance) Possible inefficient checking for emptiness. (performance) Prefer prefix ++/-- operators for non-primitive types.
* | reorder includes: add <config.h> if needed and include it at firstDavid Kalnischkies2011-09-131-2/+3
|/
* fix a bunch of cppcheck warnings/errors based on a patch byDavid Kalnischkies2011-04-161-0/+2
| | | Niels Thykier, thanks! (Closes: #622805)
* * apt-pkg/contrib/error.cc:David Kalnischkies2011-02-151-92/+77
| | | - ensure that va_list is not invalid in second try
* * apt-pkg/contrib/error.cc:David Kalnischkies2011-02-071-6/+25
| | | - remove 400 char size limit of error messages (LP: #365611)
* - [ABI BREAK] add an ErrorType option to CacheSetHelperDavid Kalnischkies2010-07-301-0/+16
| | | | | * cmdline/apt-cache.cc: - use Notice instead of Error in the CacheSetHelper messages for compat reasons. Otherwise tools like sbuild blow up
* * apt-pkg/contrib/error.{cc,h}Michael Vogt2010-07-291-2/+2
| | | - docstring cleanup
* * apt-pkg/contrib/error.{cc,h}:David Kalnischkies2010-07-101-5/+4
| | | | - remove constness of va_list parameter to fix build on amd64 and co Thanks Eric Valette! (Closes: #588610)
* add a simple stack handling to be able to delay error handlingDavid Kalnischkies2010-06-251-1/+31
|
* * apt-pkg/contrib/error.{cc,h}:David Kalnischkies2010-06-251-178/+155
| | | | - complete rewrite but use the same API - add NOTICE and DEBUG as new types of a message
* [contrib/error.cc] place a colon between errno and error text in outputDavid Kalnischkies2009-07-151-6/+7
| | | | | of GlobalError::Errno and WarningE (as it described in the comments of these methods)
* * make apt build with g++ 4.3Michael Vogt2007-09-101-1/+3
|
* * remove all the remaining #pragma implementationMichael Vogt2007-06-081-4/+0
|
* Use std C++ header names for includesArch Librarian2004-09-201-2/+2
| | | | | | Author: jgg Date: 2002-03-26 07:38:57 GMT Use std C++ header names for includes
* G++3 fixes from RandolphArch Librarian2004-09-201-2/+5
| | | | | | Author: jgg Date: 2001-05-07 05:25:13 GMT G++3 fixes from Randolph
* Join with aliencodeArch Librarian2004-09-201-2/+2
| | | | | | Author: jgg Date: 2001-02-20 07:03:16 GMT Join with aliencode
* Remove extra #errorArch Librarian2004-09-201-2/+1
| | | | | | Author: jgg Date: 1999-08-08 07:24:54 GMT Remove extra #error
* Made pthread optionalArch Librarian2004-09-201-2/+4
| | | | | | Author: jgg Date: 1999-08-05 05:55:45 GMT Made pthread optional
* Dsync mergeArch Librarian2004-09-201-7/+8
| | | | | | Author: jgg Date: 1999-01-18 06:20:07 GMT Dsync merge
* SyncArch Librarian2004-09-201-1/+27
| | | | | | Author: jgg Date: 1998-09-18 02:42:38 GMT Sync
* SyncArch Librarian2004-09-201-3/+34
| | | | | | Author: jgg Date: 1998-09-12 02:46:25 GMT Sync
* First draft of make system and name change to apt-pkgArch Librarian2004-09-201-3/+3
| | | | | | Author: jgg Date: 1998-07-12 23:58:20 GMT First draft of make system and name change to apt-pkg
* SyncArch Librarian2004-09-201-19/+55
| | | | | | Author: jgg Date: 1998-07-07 04:17:00 GMT Sync
* Base revisionsArch Librarian2004-09-201-0/+139
Author: jgg Date: 1998-07-02 02:58:12 GMT Base revisions