summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Burrows <dburrows@debian.org>2008-04-20 08:24:36 -0700
committerDaniel Burrows <dburrows@debian.org>2008-04-20 08:24:36 -0700
commit92103fbc745a2798633d7724145c8df4577a3684 (patch)
tree455b9be0fddaf90e0e6d99dfc36d7f4bff953589
parent16dbf674faefcebd7cff359bb12b9ca736a3660d (diff)
downloadaptitude-92103fbc745a2798633d7724145c8df4577a3684.tar.gz
When trying to auto-enable quietness due to not having a TTY to write to, don't decrease any existing "quiet" setting.
-rw-r--r--src/main.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main.cc b/src/main.cc
index a33e681b..bf362bdc 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -536,8 +536,9 @@ int main(int argc, char *argv[])
}
}
+ int curr_quiet = aptcfg->FindI("quiet", 0);
if(quiet == 0 && !isatty(1))
- aptcfg->SetNoUser("quiet", 1);
+ aptcfg->SetNoUser("quiet", std::max(curr_quiet, 1));
else if(seen_quiet)
aptcfg->SetNoUser("quiet", quiet);