summaryrefslogtreecommitdiff
path: root/src/daemon/dlt-daemon.h
diff options
context:
space:
mode:
authorManikandanChockalingam <manikandan.chockalingam@in.bosch.com>2018-05-18 11:17:31 +0530
committerChristoph Lipka <clipka@users.noreply.github.com>2018-05-18 07:47:31 +0200
commitda6eefe5cac244421c5af413c54e420717e11c9e (patch)
treee7eb7745fbc5e0edd3e2bede4d008a05250f1a18 /src/daemon/dlt-daemon.h
parentf549f5527148b32a15489aae75c9e4557e19cbd4 (diff)
downloadDLT-daemon-da6eefe5cac244421c5af413c54e420717e11c9e.tar.gz
IPC: Unix socket added (#43)
* IPC: Unix socket added The user can select either FIFO or UNIX socket as IPC between user library and daemon through CMakelist option. Socket path configurable for both FIFO and Unix Socket now configurable in CMake Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com> Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
Diffstat (limited to 'src/daemon/dlt-daemon.h')
-rw-r--r--src/daemon/dlt-daemon.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/daemon/dlt-daemon.h b/src/daemon/dlt-daemon.h
index 03b062e..80b0760 100644
--- a/src/daemon/dlt-daemon.h
+++ b/src/daemon/dlt-daemon.h
@@ -70,14 +70,14 @@
#define DLT_DAEMON_H
#include <limits.h> /* for NAME_MAX */
+#include <sys/time.h>
#include "dlt_daemon_common.h"
#include "dlt_user_shared.h"
#include "dlt_user_shared_cfg.h"
#include "dlt_daemon_event_handler_types.h"
#include "dlt_gateway_types.h"
-#include <dlt_offline_trace.h>
-#include <sys/time.h>
+#include "dlt_offline_trace.h"
#define DLT_DAEMON_FLAG_MAX 256
@@ -119,7 +119,11 @@ typedef struct
unsigned int offlineLogstorageMaxCounter; /**< (int) Maximum offline logstorage file counter index until wraparound */
unsigned int offlineLogstorageMaxCounterIdx; /**< (int) String len of offlineLogstorageMaxCounter*/
unsigned int offlineLogstorageCacheSize; /**< Max cache size offline logstorage cache */
+#ifdef DLT_USE_UNIX_SOCKET_IPC
+ char appSockPath[DLT_DAEMON_FLAG_MAX]; /**< Path to User socket */
+#else
char userPipesDir[NAME_MAX + 1]; /**< (String: Directory) directory where dltpipes reside (Default: /tmp/dltpipes) */
+#endif
char daemonFifoName[NAME_MAX + 1]; /**< (String: Filename) name of local fifo (Default: /tmp/dlt) */
unsigned int port; /**< port number */
char ctrlSockPath[DLT_DAEMON_FLAG_MAX]; /**< Path to Control socket */
@@ -191,6 +195,9 @@ int dlt_daemon_process_sixty_s_timer(DltDaemon *daemon, DltDaemonLocal *daemon_l
int dlt_daemon_process_systemd_timer(DltDaemon *daemon, DltDaemonLocal *daemon_local, DltReceiver *recv, int verbose);
int dlt_daemon_process_control_connect(DltDaemon *daemon, DltDaemonLocal *daemon_local, DltReceiver *recv, int verbose);
+#ifdef DLT_USE_UNIX_SOCKET_IPC
+int dlt_daemon_process_app_connect(DltDaemon *daemon, DltDaemonLocal *daemon_local, DltReceiver *recv, int verbose);
+#endif
int dlt_daemon_process_control_messages(DltDaemon *daemon, DltDaemonLocal *daemon_local, DltReceiver *recv, int verbose);
typedef int (*dlt_daemon_process_user_message_func)(DltDaemon *daemon, DltDaemonLocal *daemon_local, DltReceiver *rec, int verbose);