summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAndreas Baumann <abaumann@yahoo.com>2009-03-27 18:31:27 +0100
committerAndreas Baumann <abaumann@yahoo.com>2009-03-27 18:31:27 +0100
commitbaa035aa68b7b72fe301c933227aa2530bbec66d (patch)
treed42e0636d34289a4c00645f5cc115e26e0bb91e0 /include
parentf83210c88e7376e12b5cf0e86a073c59e4185efb (diff)
downloadwolfbones-baa035aa68b7b72fe301c933227aa2530bbec66d.tar.gz
wolfbones-baa035aa68b7b72fe301c933227aa2530bbec66d.tar.bz2
added service termination on console control events
Diffstat (limited to 'include')
-rw-r--r--include/wolf/log/messages.h2
-rw-r--r--include/wolf/service/service.h8
2 files changed, 9 insertions, 1 deletions
diff --git a/include/wolf/log/messages.h b/include/wolf/log/messages.h
index ad706e7..0d0aa70 100644
--- a/include/wolf/log/messages.h
+++ b/include/wolf/log/messages.h
@@ -184,6 +184,8 @@
#define WOLF_MSG_SERVICE_CANT_CREATE_STOP_EVENT WOLF_MSG_SERVICE_BASE+15
#define WOLF_MSG_SERVICE_WAIT_FOR_OBJECT_FAILED WOLF_MSG_SERVICE_BASE+16
#define WOLF_MSG_SERVICE_CANT_DISPATCH_SERVICE WOLF_MSG_SERVICE_BASE+17
+#define WOLF_MSG_SERVICE_CANT_REGISTER_CONSOLE_CTRL_HANDLER WOLF_MSG_SERVICE_BASE+18
+#define WOLF_MSG_SERVICE_CONSOLE_CTRL_RECEIVED WOLF_MSG_SERVICE_BASE+19
#ifdef __cplusplus
extern "C" {
diff --git a/include/wolf/service/service.h b/include/wolf/service/service.h
index 2033117..2645bc3 100644
--- a/include/wolf/service/service.h
+++ b/include/wolf/service/service.h
@@ -116,7 +116,13 @@ typedef enum wolf_service_event_t {
*
* @return the event which happened
*/
-wolf_service_event_t wolf_service_events_suspend( int timeout, wolf_error_t *error );
+typedef wolf_service_event_t (*LPWOLF_SERVICE_SUSPEND_FUNCTION)( int timeout, wolf_error_t *error );
+
+/**
+ * The current version of the suspend function, depends whether we started the service
+ * in the console or really as service
+ */
+extern LPWOLF_SERVICE_SUSPEND_FUNCTION wolf_service_events_suspend;
#ifdef __cplusplus
}