Skip to content

Commit

Permalink
Add shutdown method
Browse files Browse the repository at this point in the history
  • Loading branch information
Teddy Reed committed Jul 20, 2016
1 parent bebf89f commit 3b777ab
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions osquery/extension_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
from __future__ import print_function
from __future__ import unicode_literals

import sys

from osquery.extensions.Extension import Iface
from osquery.extensions.ttypes import ExtensionResponse, ExtensionStatus
from osquery.singleton import Singleton
Expand Down Expand Up @@ -60,6 +62,10 @@ def add_plugin(self, plugin):
if obj.name() not in self._plugins[obj.registry_name()]:
self._plugins[obj.registry_name()][obj.name()] = obj

def shutdown(self):
"""The osquery extension manager requested a shutdown"""
sys.exit(0)

def registry(self):
"""Accessor for the internal _registry member variable"""
return self._registry
Expand Down

0 comments on commit 3b777ab

Please sign in to comment.