X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fip_pipeline%2Fconfig_parse_tm.c;h=e75eed71f6b1b409ca8cab040754a14609919d2b;hb=9e09761b43179caa3bc825a83b18e3b27ddf7f10;hp=cdebbdc9f958f71afd2b13056f1ef19022f3a163;hpb=7f64b9c004aa39d50fd5ee254b399e4267a5aa5d;p=dpdk.git diff --git a/examples/ip_pipeline/config_parse_tm.c b/examples/ip_pipeline/config_parse_tm.c index cdebbdc9f9..e75eed71f6 100644 --- a/examples/ip_pipeline/config_parse_tm.c +++ b/examples/ip_pipeline/config_parse_tm.c @@ -349,7 +349,7 @@ tm_cfgfile_load_sched_subport( char *tokens[2] = {NULL, NULL}; int n_tokens; int begin, end; - char name[CFG_NAME_LEN]; + char name[CFG_NAME_LEN + 1]; profile = atoi(entries[j].value); strncpy(name, @@ -399,7 +399,7 @@ tm_cfgfile_load(struct app_pktq_tm_params *tm) memset(tm->sched_subport_params, 0, sizeof(tm->sched_subport_params)); memset(tm->sched_pipe_profiles, 0, sizeof(tm->sched_pipe_profiles)); - memset(&tm->sched_port_params, 0, sizeof(tm->sched_pipe_profiles)); + memset(&tm->sched_port_params, 0, sizeof(tm->sched_port_params)); for (i = 0; i < APP_MAX_SCHED_SUBPORTS * APP_MAX_SCHED_PIPES; i++) tm->sched_pipe_to_profile[i] = -1;