From 0a54d46589780b1306c2af47b55e405e47b5de54 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 5 Apr 2015 12:19:55 -0400 Subject: [PATCH] Hooks: With rc.debug.hooks=2, shows hook arguments --- src/Hooks.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/Hooks.cpp b/src/Hooks.cpp index 92cd86e98..6d9fef7cc 100644 --- a/src/Hooks.cpp +++ b/src/Hooks.cpp @@ -569,13 +569,18 @@ int Hooks::callHookScript ( for (i = input.begin (); i != input.end (); ++i) inputStr += *i + "\n"; - std::string outputStr; std::vector args; - int status; - buildHookScriptArgs (args); + if (_debug >= 2) + { + context.debug ("Hooks: args"); + for (auto arg: args) + context.debug (" " + arg); + } // Measure time for each hook if running in debug + int status; + std::string outputStr; if (_debug >= 2) { Timer timer_per_hook("Hooks::execute (" + script + ")");