mirror of
https://github.com/Ylianst/MeshAgent
synced 2025-12-17 16:53:13 +00:00
Fixed warnings
This commit is contained in:
@@ -3845,7 +3845,7 @@ int MeshAgent_AgentMode(MeshAgentHostContainer *agentHost, int paramLen, char **
|
|||||||
int ixr = 0;
|
int ixr = 0;
|
||||||
for (ri = 0; ri < paramLen; ++ri)
|
for (ri = 0; ri < paramLen; ++ri)
|
||||||
{
|
{
|
||||||
int len = strnlen_s(param[ri], 4096);
|
int len = (int)strnlen_s(param[ri], 4096);
|
||||||
int ix;
|
int ix;
|
||||||
if ((ix=ILibString_IndexOf(param[ri], len, "=", 1)) > 2 && strncmp(param[ri], "--", 2)==0)
|
if ((ix=ILibString_IndexOf(param[ri], len, "=", 1)) > 2 && strncmp(param[ri], "--", 2)==0)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -118,7 +118,7 @@ void ILibSimpleDataStore_Cached(ILibSimpleDataStore dataStore, char* key, int ke
|
|||||||
if (root->cacheTable == NULL) { root->cacheTable = ILibHashtable_Create(); }
|
if (root->cacheTable == NULL) { root->cacheTable = ILibHashtable_Create(); }
|
||||||
ILibSimpleDataStore_CacheEntry *entry = (ILibSimpleDataStore_CacheEntry*)ILibMemory_Allocate(sizeof(ILibSimpleDataStore_CacheEntry) + valueLen, 0, NULL, NULL);
|
ILibSimpleDataStore_CacheEntry *entry = (ILibSimpleDataStore_CacheEntry*)ILibMemory_Allocate(sizeof(ILibSimpleDataStore_CacheEntry) + valueLen, 0, NULL, NULL);
|
||||||
entry->valueLength = valueLen;
|
entry->valueLength = valueLen;
|
||||||
memcpy_s(entry->value, valueLen, value, valueLen);
|
if (valueLen > 0) { memcpy_s(entry->value, valueLen, value, valueLen); }
|
||||||
|
|
||||||
ILibHashtable_Put(root->cacheTable, NULL, key, keyLen, entry);
|
ILibHashtable_Put(root->cacheTable, NULL, key, keyLen, entry);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user