summaryrefslogtreecommitdiff
path: root/src/daemon/dlt-daemon.c
diff options
context:
space:
mode:
authorChristian Muck <christian.muck@bmw.de>2012-05-08 09:55:26 +0200
committerChristian Muck <christian.muck@bmw.de>2012-05-08 09:58:09 +0200
commit425c366dc147652c9b2b0af8a26f66d7a457feff (patch)
treea66ddfe45817a6d64c1cd87ab26eda4ce5359d7b /src/daemon/dlt-daemon.c
parentf7828cf1a677b0d651c0477176099d66550037fd (diff)
downloadDLT-daemon-425c366dc147652c9b2b0af8a26f66d7a457feff.tar.gz
Added define statement for initial value of file descriptor and (-1). Updated the user_handle of the daemon and user
Signed-off-by: Christian Muck <christian.muck@bmw.de>
Diffstat (limited to 'src/daemon/dlt-daemon.c')
-rw-r--r--src/daemon/dlt-daemon.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/daemon/dlt-daemon.c b/src/daemon/dlt-daemon.c
index 69e4072..476f442 100644
--- a/src/daemon/dlt-daemon.c
+++ b/src/daemon/dlt-daemon.c
@@ -1582,7 +1582,7 @@ int dlt_daemon_process_user_message_register_context(DltDaemon *daemon, DltDaemo
dlt_message_free(&msg, verbose);
}
- if (context->user_handle!=0)
+ if (context->user_handle >= DLT_FD_MINIMUM)
{
/* This call also replaces the default values with the values defined for default */
if (dlt_daemon_user_send_log_level(daemon, context, verbose)==-1)
@@ -2125,8 +2125,7 @@ int dlt_daemon_process_user_message_set_app_ll_ts(DltDaemon *daemon, DltDaemonLo
context->trace_status = usercontext->trace_status; /* No endianess conversion necessary */
/* The folowing function sends also the trace status */
- if ((context->user_handle==0) ||
- (dlt_daemon_user_send_log_level(daemon, context, verbose)!=0))
+ if (context->user_handle >= DLT_FD_MINIMUM && dlt_daemon_user_send_log_level(daemon, context, verbose)!=0)
{
context->log_level = old_log_level;
context->trace_status = old_trace_status;