summaryrefslogtreecommitdiff
path: root/apt-private
diff options
context:
space:
mode:
Diffstat (limited to 'apt-private')
-rw-r--r--apt-private/private-cmndline.cc5
-rw-r--r--apt-private/private-output.cc4
2 files changed, 7 insertions, 2 deletions
diff --git a/apt-private/private-cmndline.cc b/apt-private/private-cmndline.cc
index a37af6b58..b05ec8945 100644
--- a/apt-private/private-cmndline.cc
+++ b/apt-private/private-cmndline.cc
@@ -409,6 +409,7 @@ std::vector<CommandLine::Args> getCommandArgs(APT_CMD const Program, char const
// general options
addArg(0, "color", "APT::Color", 0);
addArg('q', "quiet", "quiet", CommandLine::IntLevel);
+ addArg(0, "audit", "APT::Audit", 0);
addArg('q', "silent", "quiet", CommandLine::IntLevel);
addArg('c', "config-file", 0, CommandLine::ConfigFile);
addArg('o', "option", 0, CommandLine::ArbItem);
@@ -601,7 +602,9 @@ unsigned short DispatchCommandLine(CommandLine &CmdL, std::vector<CommandLine::D
// Print any errors or warnings found during parsing
bool const Errors = _error->PendingError();
- if (_config->FindI("quiet",0) > 0)
+ if (_config->FindB("APT::Audit"))
+ _error->DumpErrors(GlobalError::AUDIT);
+ else if (_config->FindI("quiet",0) > 0)
_error->DumpErrors();
else
_error->DumpErrors(GlobalError::NOTICE);
diff --git a/apt-private/private-output.cc b/apt-private/private-output.cc
index 179078e80..35fe9cdca 100644
--- a/apt-private/private-output.cc
+++ b/apt-private/private-output.cc
@@ -799,7 +799,9 @@ bool YnPrompt(char const * const Question, bool const Default, bool const ShowGl
// if we ask interactively, show warnings/notices before the question
if (ShowGlobalErrors == true && AssumeYes == false && AssumeNo == false)
{
- if (_config->FindI("quiet",0) > 0)
+ if (_config->FindB("APT::Audit"))
+ _error->DumpErrors(c2o, GlobalError::AUDIT);
+ else if (_config->FindI("quiet",0) > 0)
_error->DumpErrors(c2o);
else
_error->DumpErrors(c2o, GlobalError::NOTICE);