summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIngo Huerner <ingo.huerner@xse.de>2014-03-17 10:27:49 +0100
committerIngo Huerner <ingo.huerner@xse.de>2014-03-17 10:27:49 +0100
commit184bbd512b7f64b53e72376a0b892a11b34f9094 (patch)
treed802b986187ba8105e5c883525d63109135dbe1d
parentf88196633ec339ee6650429cd144d2e632bd631f (diff)
downloadpersistence-client-library-184bbd512b7f64b53e72376a0b892a11b34f9094.tar.gz
Fixed bug 171; return the correct error code EPERS_MAXHANDLE instead -1
-rw-r--r--src/persistence_client_library.c2
-rw-r--r--src/persistence_client_library_dbus_service.c2
-rw-r--r--src/persistence_client_library_handle.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/persistence_client_library.c b/src/persistence_client_library.c
index 612b50c..4eba3bf 100644
--- a/src/persistence_client_library.c
+++ b/src/persistence_client_library.c
@@ -52,7 +52,7 @@ int pclInitLibrary(const char* appName, int shutdownMode)
{
gShutdownMode = shutdownMode;
- DLT_REGISTER_CONTEXT(gDLTContext,"pers","Context for persistence client library logging");
+ DLT_REGISTER_CONTEXT(gDLTContext,"PCL","Context for persistence client library logging");
DLT_LOG(gDLTContext, DLT_LOG_INFO, DLT_STRING("pclInitLibrary => I N I T Persistence Client Library - "), DLT_STRING(gAppId),
DLT_STRING("- init counter: "), DLT_INT(gPclInitialized) );
diff --git a/src/persistence_client_library_dbus_service.c b/src/persistence_client_library_dbus_service.c
index 559b7ad..608ae87 100644
--- a/src/persistence_client_library_dbus_service.c
+++ b/src/persistence_client_library_dbus_service.c
@@ -30,6 +30,7 @@
#include <unistd.h>
#include <stdlib.h>
+
pthread_cond_t gDbusInitializedCond = PTHREAD_COND_INITIALIZER;
pthread_mutex_t gDbusInitializedMtx = PTHREAD_MUTEX_INITIALIZER;
@@ -38,7 +39,6 @@ pthread_mutex_t gDbusPendingRegMtx = PTHREAD_MUTEX_INITIALIZER;
pthread_mutex_t gDeliverpMtx = PTHREAD_MUTEX_INITIALIZER;
-
pthread_mutex_t gMainCondMtx = PTHREAD_MUTEX_INITIALIZER;
pthread_cond_t gMainLoopCond = PTHREAD_COND_INITIALIZER;
diff --git a/src/persistence_client_library_handle.c b/src/persistence_client_library_handle.c
index 704d715..7be6e3b 100644
--- a/src/persistence_client_library_handle.c
+++ b/src/persistence_client_library_handle.c
@@ -68,7 +68,7 @@ int get_persistence_handle_idx()
}
else
{
- handle = -1;
+ handle = EPERS_MAXHANDLE;
DLT_LOG(gDLTContext, DLT_LOG_ERROR, DLT_STRING("get_persistence_handle_idx => Reached maximum of open handles: "), DLT_INT(MaxPersHandle));
}
}