From 7e2582f2b8d1c627f9d1bebc1a09620bbe1f7e29 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 19 Oct 2014 00:57:30 -0400 Subject: [PATCH] Hooks - Fixed bug where the identifier "on-modify" contained some bogus UTF8. - Ensured that every input line has a \n. --- src/Hooks.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Hooks.cpp b/src/Hooks.cpp index 5c68a1e3c..24967d74e 100644 --- a/src/Hooks.cpp +++ b/src/Hooks.cpp @@ -297,7 +297,7 @@ void Hooks::onModify (const Task& before, std::vector & tasks) context.timer_hooks.start (); - std::vector matchingScripts = scripts ("on-modіfy"); + std::vector matchingScripts = scripts ("on-modify"); if (matchingScripts.size ()) { // Prepare invariants. @@ -463,7 +463,9 @@ int Hooks::callHookScript ( } std::string inputStr; - join (inputStr, "\n", input); + std::vector ::const_iterator i; + for (i = input.begin (); i != input.end (); ++i) + inputStr += *i + "\n"; std::string outputStr; std::vector args;