From d290b8792bb0a8988cb469e50dfcfdf87f7fde2d Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 8 Sep 2014 00:04:09 -0400 Subject: [PATCH] Context - Relocated Hooks::onLaunch call from the end of ::initialize to the beginning of ::run. - Added a TDB2::commit between ::dispatch and Hooks::onExit. --- src/Context.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Context.cpp b/src/Context.cpp index 9f3f9f31c..de8736310 100644 --- a/src/Context.cpp +++ b/src/Context.cpp @@ -205,7 +205,6 @@ int Context::initialize (int argc, const char** argv) // First opportunity to run a hook script. hooks.initialize (); - hooks.onLaunch (); } catch (const std::string& message) @@ -283,8 +282,10 @@ int Context::run () try { + hooks.onLaunch (); rc = dispatch (output); - hooks.onExit (); + tdb2.commit (); // Harmless if called when nothing changed. + hooks.onExit (); // No chance to update data. std::stringstream s; s << "Perf "