aboutsummaryrefslogtreecommitdiff
path: root/paludis/command_output_manager.cc
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-02-03 16:53:09 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-02-03 16:53:09 +0000
commit35831832b06566d7dd316c9a4cf6d12f4727b978 (patch)
tree3e3bb03983e9554a0d278a6928d48e2bb7cc72b4 /paludis/command_output_manager.cc
parent6a432ad8d444deda7fc65746e8028e21dfde2d1e (diff)
downloadpaludis-35831832b06566d7dd316c9a4cf6d12f4727b978.tar.gz
paludis-35831832b06566d7dd316c9a4cf6d12f4727b978.tar.xz
OutputManager::ignore_succeeded
Diffstat (limited to 'paludis/command_output_manager.cc')
-rw-r--r--paludis/command_output_manager.cc12
1 files changed, 10 insertions, 2 deletions
diff --git a/paludis/command_output_manager.cc b/paludis/command_output_manager.cc
index c9dbb5eeb..da128f1c3 100644
--- a/paludis/command_output_manager.cc
+++ b/paludis/command_output_manager.cc
@@ -59,6 +59,7 @@ namespace paludis
std::unique_ptr<SafeOFStream> stderr_stream;
bool already_nothing_more_to_come;
+ bool ignore_succeeded;
Imp(
const std::string & s,
@@ -74,7 +75,8 @@ namespace paludis
stderr_command(se),
succeeded_command(su),
nothing_more_to_come_command(n),
- already_nothing_more_to_come(false)
+ already_nothing_more_to_come(false),
+ ignore_succeeded(false)
{
}
};
@@ -180,7 +182,7 @@ CommandOutputManager::message(const MessageType, const std::string &)
void
CommandOutputManager::succeeded()
{
- if (! _imp->succeeded_command.empty())
+ if ((! _imp->ignore_succeeded) && (! _imp->succeeded_command.empty()))
{
Process process(ProcessCommand(_imp->succeeded_command));
if (0 != process.run().wait())
@@ -189,6 +191,12 @@ CommandOutputManager::succeeded()
}
void
+CommandOutputManager::ignore_succeeded()
+{
+ _imp->ignore_succeeded = true;
+}
+
+void
CommandOutputManager::flush()
{
}