numam-dpdk/examples/l3fwd
Keith Wiles 9d5ca53239 examples: fix optind reset
The variable optind should be reset to one not zero.

From the man page:
"The variable optind is the index of the next element to be processed in
argv.  The system initializes this value to 1.
The caller can reset it to 1 to restart scanning of the same argv, or when
scanning a new argument vector.”

The problem I saw with my application was trying to parse the wrong
option, which can happen as DPDK parses the first part of the command line
and the application parses the second part. If you call getopt() multiple
times in the same execution, the behavior is not maintained when using
zero for optind.

Signed-off-by: Keith Wiles <keith.wiles@intel.com>
2017-03-10 15:38:47 +01:00
..
l3fwd_em_hlm_sse.h hash: remove aliases for bulk lookup 2016-04-20 13:49:36 +02:00
l3fwd_em_sse.h examples/l3fwd: fix size of destination port ids 2016-03-31 22:56:00 +02:00
l3fwd_em.c examples/l3fwd: use accelerated CRC on ARM 2016-10-25 18:49:18 +02:00
l3fwd_em.h examples/l3fwd: fix using packet type blindly 2016-03-25 19:53:00 +01:00
l3fwd_lpm_sse.h examples/l3fwd: fix size of destination port ids 2016-03-31 22:56:00 +02:00
l3fwd_lpm.c remove unused ring includes 2016-09-16 10:16:02 +02:00
l3fwd_lpm.h examples/l3fwd: fix size of destination port ids 2016-03-31 22:56:00 +02:00
l3fwd_sse.h examples/l3fwd: fix crash with gcc 5 2016-04-06 11:35:33 +02:00
l3fwd.h examples/l3fwd: enable 4M hash for all 64-bit archs 2016-10-13 14:37:48 +02:00
main.c examples: fix optind reset 2017-03-10 15:38:47 +01:00
Makefile examples/l3fwd: modularize 2016-02-28 21:56:19 +01:00