diff --git a/src/rrd_first.c b/src/rrd_first.c
index ab3bd497b9b4c0aaeab5b400be81cd8f48074045..eee8140887fc082c2710b72151eaf30fdad943c3 100644 (file)
--- a/src/rrd_first.c
+++ b/src/rrd_first.c
{
int target_rraindex=0;
char *endptr;
+ optind = 0; opterr = 0; /* initialize getopt */
while (1){
static struct option long_options[] =
};
int option_index = 0;
int opt;
+ optind = 0; opterr = 0; /* initialize getopt */
opt = getopt_long(argc, argv, "", long_options, &option_index);
if(opt == EOF)