diff options
| author | Maxime Coste <frrrwww@gmail.com> | 2014-03-20 08:29:41 +0000 |
|---|---|---|
| committer | Maxime Coste <frrrwww@gmail.com> | 2014-03-20 08:29:41 +0000 |
| commit | c48bdbe4f1b7d085f63ac3e133b2d9c53951cbfd (patch) | |
| tree | bffd86df094cf6aa762bf89e2f219d891c0b9b1b /src/hook_manager.hh | |
| parent | be417d361602af9871944070c00eca4fc4549775 (diff) | |
exec and eval support the -no-hooks option
Hooks gets disabled during the execution of the commands
Diffstat (limited to 'src/hook_manager.hh')
| -rw-r--r-- | src/hook_manager.hh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/hook_manager.hh b/src/hook_manager.hh index 1c86bfb1..794f8077 100644 --- a/src/hook_manager.hh +++ b/src/hook_manager.hh @@ -35,6 +35,13 @@ private: class GlobalHooks : public HookManager, public Singleton<GlobalHooks> { +public: + bool are_hooks_disabled() const; + + void disable_hooks() { ++m_disabled; } + void enable_hooks() { --m_disabled; } +private: + int m_disabled = 0; }; } |
