From 178c71d985d08f6fa9c6662933508a8a410fed7c Mon Sep 17 00:00:00 2001 From: Josh Cardenzana Date: Thu, 26 Oct 2017 16:01:35 +0200 Subject: [PATCH] Conditional passing of logger to GCTACubePsf (#2262) --- src/ctpsfcube/ctpsfcube.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/ctpsfcube/ctpsfcube.cpp b/src/ctpsfcube/ctpsfcube.cpp index 5d69b4b..d94f49a 100644 --- a/src/ctpsfcube/ctpsfcube.cpp +++ b/src/ctpsfcube/ctpsfcube.cpp @@ -223,8 +223,11 @@ void ctpsfcube::run(void) // Write header into logger log_header1(TERSE, "Generate PSF cube"); + // Set pointer to logger dependent on chattiness + GLog* logger = (logNormal()) ? &log : NULL; + // Fill PSF cube - m_psfcube.fill(m_obs, &log); + m_psfcube.fill(m_obs, logger); // Write PSF cube into logger log_string(EXPLICIT, m_psfcube.print(m_chatter)); -- libgit2 0.21.4