diff --git a/src/Context.cpp b/src/Context.cpp index ab6e6707b..9f3f9f31c 100644 --- a/src/Context.cpp +++ b/src/Context.cpp @@ -284,8 +284,7 @@ int Context::run () try { rc = dispatch (output); - if (hooks.onExit ()) - tdb2.commit (); + hooks.onExit (); std::stringstream s; s << "Perf " diff --git a/src/Hooks.cpp b/src/Hooks.cpp index 980355dbc..bea5c3ae0 100644 --- a/src/Hooks.cpp +++ b/src/Hooks.cpp @@ -136,13 +136,10 @@ void Hooks::onLaunch () // Exit: // 0 Means: - all emitted non-JSON lines become footnote entries // non-0 Means: - all emitted non-JSON lines become error entries -bool Hooks::onExit () +void Hooks::onExit () { context.timer_hooks.start (); - // Status indicates whether hooks resulted in new/modified tasks. - bool status = false; - std::vector matchingScripts = scripts ("on-exit"); std::vector ::iterator i; for (i = matchingScripts.begin (); i != matchingScripts.end (); ++i) @@ -169,7 +166,6 @@ bool Hooks::onExit () } context.timer_hooks.stop (); - return status; } //////////////////////////////////////////////////////////////////////////////// diff --git a/src/Hooks.h b/src/Hooks.h index f646de123..0af7e9bed 100644 --- a/src/Hooks.h +++ b/src/Hooks.h @@ -41,7 +41,7 @@ public: void initialize (); void onLaunch (); - bool onExit (); + void onExit (); void onAdd (Task&); void onModify (const Task&, Task&);