diff options
author | Ingo Huerner <ingo.huerner@xse.de> | 2014-07-09 15:32:59 +0200 |
---|---|---|
committer | Ingo Huerner <ingo.huerner@xse.de> | 2014-07-09 15:32:59 +0200 |
commit | c2b8dbd1a8cc3b7a2edd57beb8f548e5f890dc5b (patch) | |
tree | 889bbb42b9b0243c352883af5e28c563d3ff7236 /src/persistence_client_library_key.c | |
parent | 4680fad3bd70ee363838ceb74c0259e5718be3fa (diff) | |
download | persistence-client-library-c2b8dbd1a8cc3b7a2edd57beb8f548e5f890dc5b.tar.gz |
Fixed a problem with getting the size of the default data; extended tests to increase code coverage
Diffstat (limited to 'src/persistence_client_library_key.c')
-rw-r--r-- | src/persistence_client_library_key.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/persistence_client_library_key.c b/src/persistence_client_library_key.c index 3540251..c73cf4c 100644 --- a/src/persistence_client_library_key.c +++ b/src/persistence_client_library_key.c @@ -49,7 +49,7 @@ int pclKeyHandleOpen(unsigned int ldbid, const char* resource_id, unsigned int u { PersistenceInfo_s dbContext; - char dbKey[DbKeyMaxLen] = {0}; // database key + char dbKey[DbKeyMaxLen] = {0}; // database key char dbPath[DbPathMaxLen] = {0}; // database location dbContext.context.ldbid = ldbid; @@ -338,7 +338,7 @@ int pclKeyGetSize(unsigned int ldbid, const char* resource_id, unsigned int user { if( dbContext.configKey.storage < PersistenceStorage_LastEntry) // check if store policy is valid { - data_size = persistence_get_data_size(dbPath, dbKey, &dbContext); + data_size = persistence_get_data_size(dbPath, dbKey, resource_id, &dbContext); } else { @@ -529,11 +529,8 @@ int regNotifyOnChange(unsigned int ldbid, const char* resource_id, unsigned int } else { - DLT_LOG(gPclDLTContext, DLT_LOG_ERROR, - DLT_STRING("regNotifyOnChange: Not allowed! Resource is local or it is a file:"), - DLT_STRING(resource_id), - DLT_STRING("LDBID:"), - DLT_UINT(ldbid)); + DLT_LOG(gPclDLTContext, DLT_LOG_ERROR, DLT_STRING("regNotifyOnChange: Not allowed! Resource is local or it is a file:"), + DLT_STRING(resource_id), DLT_STRING("LDBID:"), DLT_UINT(ldbid)); rval = EPERS_NOTIFY_NOT_ALLOWED; } } |