@@ -480,9 +480,10 @@ cfg_parse_tcp(ipx_ctx_t *ctx, fds_xml_ctx_t *root, struct conf_params *cfg, enum
480480 // Prepare the TRAP interface specification
481481 char * res = NULL ;
482482 const char * trap_ifc = (type == SPEC_TCP ) ? "t" : "T" ;
483- if (cfg_str_append (& res , "%s:%" PRIu16 ":%" PRIu64 , trap_ifc , port , max_conn ) != IPX_OK
483+ if (cfg_str_append (& res , "%s:%" PRIu16 , trap_ifc , port ) != IPX_OK
484484 || (type == SPEC_TCP_TLS
485- && cfg_str_append (& res , ":%s:%s:%s" , file_key , file_cert , file_ca ) != IPX_OK )) {
485+ && cfg_str_append (& res , ":%s:%s:%s" , file_key , file_cert , file_ca ) != IPX_OK )
486+ || (cfg_str_append (& res , ":max_clients=%" PRIu64 , max_conn ) != IPX_OK )) {
486487 IPX_CTX_ERROR (ctx , "Unable to allocate memory (%s:%d)" , __FILE__ , __LINE__ );
487488 free (file_ca ); free (file_cert ); free (file_key );
488489 free (res );
@@ -544,7 +545,7 @@ cfg_parse_unix(ipx_ctx_t *ctx, fds_xml_ctx_t *root, struct conf_params *cfg)
544545
545546 // Prepare the TRAP interface specification
546547 char * res = NULL ;
547- if (cfg_str_append (& res , "u:%s:%" PRIu64 , name , max_conn ) != IPX_OK ) {
548+ if (cfg_str_append (& res , "u:%s:max_clients= %" PRIu64 , name , max_conn ) != IPX_OK ) {
548549 IPX_CTX_ERROR (ctx , "Unable to allocate memory (%s:%d)" , __FILE__ , __LINE__ );
549550 free (name );
550551 return IPX_ERR_NOMEM ;
0 commit comments