X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=app%2Ftest-pmd%2Fconfig.c;fp=app%2Ftest-pmd%2Fconfig.c;h=8cf84ccd31e8a6228d2866f794932df9642b66ef;hb=7eeda4d55af439495e7463f94cd30bfa39bd39d5;hp=d93941f0319ae6a04a244811f3e63c908b346996;hpb=35594a9b6f96ac6e45bbb851d9180c841c35cfff;p=dpdk.git diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index d93941f031..8cf84ccd31 100644 --- a/app/test-pmd/config.c +++ b/app/test-pmd/config.c @@ -2616,9 +2616,6 @@ set_fwd_ports_list(unsigned int *portlist, unsigned int nb_pt) * If the user wants to use only the ports 1,2 then the input * is 1,2. * valid characters are '-' and ',' - * invalid chars like '.' or '#' will result in - * EAL: Error - exiting with code: 1 - * Cause: Invalid fwd port list * @param[out] values * This array will be filled with a list of port IDs * based on the user input @@ -2630,7 +2627,8 @@ set_fwd_ports_list(unsigned int *portlist, unsigned int nb_pt) * 1) Number of elements in the values array * 2) Maximum value of each element in the values array * @return - * -returns total count of parsed port IDs + * On success, returns total count of parsed port IDs + * On failure, returns 0 */ static unsigned int parse_port_list(const char *list, unsigned int *values, unsigned int maxsize) @@ -2642,7 +2640,7 @@ parse_port_list(const char *list, unsigned int *values, unsigned int maxsize) unsigned int marked[maxsize]; if (list == NULL || values == NULL) - return -1; + return 0; for (i = 0; i < (int)maxsize; i++) marked[i] = 0;