diff options
author | sharath <sharathkumarboyanapally@gmail.com> | 2018-11-19 20:51:50 +0530 |
---|---|---|
committer | sharath <sharathkumarboyanapally@gmail.com> | 2018-12-03 09:38:59 +0530 |
commit | f35c043fd045b77fa81a76e477fbe10f32ec58d3 (patch) | |
tree | 614c9df3907e50857af003ddb4e28fb89a92f6ed /src/nSocket | |
parent | 960e7c662a8981a563f692f4dcdd221f1cfd3783 (diff) |
Fix: removing unwanted json elements
Change-Id: Id77dd8100bf1a8474b2a6d4f08be1adbc313064e
Signed-off-by: sharath <sharathkumarboyanapally@gmail.com>
Diffstat (limited to 'src/nSocket')
-rw-r--r-- | src/nSocket/nstack/nstack_info_parse.c | 28 |
1 files changed, 24 insertions, 4 deletions
diff --git a/src/nSocket/nstack/nstack_info_parse.c b/src/nSocket/nstack/nstack_info_parse.c index 84538cc..8b2d62f 100644 --- a/src/nSocket/nstack/nstack_info_parse.c +++ b/src/nSocket/nstack/nstack_info_parse.c @@ -66,8 +66,14 @@ } \ else \ { \ - NSSOC_LOGERR("can't get obj from %s index:%d", name, (index)); \ - goto RETURN_ERROR; \ + if (strcmp(name, "deploytype") == 0 || strcmp(name, "stackid") == 0) \ + { \ + NSSOC_LOGERR("can't get obj from %s index:%d", name, (index)); \ + } \ + else\ + { \ + NSSOC_LOGWAR("can't get obj from %s index:%d", name, (index)); \ + } \ } \ } while ( 0 ); @@ -161,14 +167,28 @@ nstack_parse_module_cfg_json (char *param) } else { - NSSOC_LOGERR ("can't get value from loadtype index:%d", index); - goto RETURN_ERROR; + if (strcmp (g_nstack_module_desc[icnt].modName, "kernel") == 0) + { + g_nstack_module_desc[icnt].libtype = NSTACK_LIB_LOAD_STATIC; + } + else + { + g_nstack_module_desc[icnt].libtype = NSTACK_LIB_LOAD_DYN; + } + NSSOC_LOGWAR ("can't get the value of loadtype for module:%s", + g_nstack_module_desc[icnt].modName); } + NSSBR_LOGINF ("load type of %d has been chosen", + g_nstack_module_desc[icnt].libtype); NSTACK_JSON_PARSE_INT (module_obj, "deploytype", MODULE_NAME_MAX, g_nstack_module_desc[icnt].deploytype, index); NSTACK_JSON_PARSE_INT (module_obj, "maxfd", MODULE_NAME_MAX, g_nstack_module_desc[icnt].maxfdid, index); + if (g_nstack_module_desc[icnt].maxfdid == 0) + { + g_nstack_module_desc[icnt].maxfdid = 1024; + } NSTACK_JSON_PARSE_INT (module_obj, "minfd", MODULE_NAME_MAX, g_nstack_module_desc[icnt].minfdid, index); NSTACK_JSON_PARSE_INT (module_obj, "priorty", MODULE_NAME_MAX, |