From 05a15ed660f8b43c85242fed1a863853e8c749b3 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Mon, 6 Jan 2025 17:48:19 +0100 Subject: Reduce chance of lines being cut and mixed up when printing from the task threads. --- src/task_fn.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/task_fn.cc') diff --git a/src/task_fn.cc b/src/task_fn.cc index 2fa0ad6..873dc44 100644 --- a/src/task_fn.cc +++ b/src/task_fn.cc @@ -68,9 +68,10 @@ int TaskFn::runInner() if(settings.verbose >= 0) { - std::cout << "Fn" << " " << - sourceFile.lexically_normal().string() << " => " << - targetFile().lexically_normal().string() << std::endl; + std::string output = "Fn " + + sourceFile.lexically_normal().string() + " => " + + targetFile().lexically_normal().string() + '\n'; + std::cout << output << std::flush; } return config.function(sourceFile.string(), -- cgit v1.2.3