diff options
author | Radek Novacek <rnovacek@redhat.com> | 2013-09-13 10:17:33 +0200 |
---|---|---|
committer | Radek Novacek <rnovacek@redhat.com> | 2013-09-19 09:19:36 +0200 |
commit | be6bc05807a5519e5e054353d70494e712e6022c (patch) | |
tree | 64a78842bd95f21e394171241e71886ac8f347b5 /src/service-dbus | |
parent | ba68ac8759f664b9079ca9d5b6772285f6433be6 (diff) | |
download | openlmi-providers-be6bc05807a5519e5e054353d70494e712e6022c.tar.gz openlmi-providers-be6bc05807a5519e5e054353d70494e712e6022c.tar.xz openlmi-providers-be6bc05807a5519e5e054353d70494e712e6022c.zip |
Call lmi_init function from providers
Diffstat (limited to 'src/service-dbus')
-rw-r--r-- | src/service-dbus/LMI_ServiceProvider.c | 1 | ||||
-rw-r--r-- | src/service-dbus/util/serviceutil.c | 3 | ||||
-rw-r--r-- | src/service-dbus/util/serviceutil.h | 4 |
3 files changed, 8 insertions, 0 deletions
diff --git a/src/service-dbus/LMI_ServiceProvider.c b/src/service-dbus/LMI_ServiceProvider.c index 372ad9a..e1329c7 100644 --- a/src/service-dbus/LMI_ServiceProvider.c +++ b/src/service-dbus/LMI_ServiceProvider.c @@ -29,6 +29,7 @@ static const CMPIBroker* _cb = NULL; static void LMI_ServiceInitialize() { + lmi_init(provider_name, _cb, provider_config_defaults); } static CMPIStatus LMI_ServiceCleanup( diff --git a/src/service-dbus/util/serviceutil.c b/src/service-dbus/util/serviceutil.c index 70127fe..ac933c5 100644 --- a/src/service-dbus/util/serviceutil.c +++ b/src/service-dbus/util/serviceutil.c @@ -39,6 +39,9 @@ #define SERVICE_INTERFACE "org.freedesktop.systemd1.Service" #define PROPERTY_INTERFACE "org.freedesktop.DBus.Properties" +const char *provider_name = "service"; +const ConfigEntry *provider_config_defaults = NULL; + void service_free_slist(SList *slist) { int i; diff --git a/src/service-dbus/util/serviceutil.h b/src/service-dbus/util/serviceutil.h index 4b54aaf..020cfb7 100644 --- a/src/service-dbus/util/serviceutil.h +++ b/src/service-dbus/util/serviceutil.h @@ -23,9 +23,13 @@ #define SERVICEUTIL_H #include <stdio.h> +#include "openlmi.h" #define ARRAY_SIZE(name) (sizeof(name) / sizeof(name[0])) +const char *provider_name; +const ConfigEntry *provider_config_defaults; + enum OperationalStatus {OS_UNKNOWN = 0, OS_OK = 2, OS_ERROR = 6, OS_STARTING = 8, OS_STOPPING = 9, OS_STOPPED = 10, OS_COMPLETED = 17}; enum ServiceEnabledDefault {ENABLED = 2, DISABLED = 3, NOT_APPLICABLE = 5}; |