]> git.ipfire.org Git - thirdparty/rrdtool-1.x.git/commitdiff
Fix error 'optind': undeclared identifier 821/head
authorWolfgang Stöggl <c72578@yahoo.de>
Mon, 18 Sep 2017 11:09:21 +0000 (13:09 +0200)
committerWolfgang Stöggl <c72578@yahoo.de>
Mon, 18 Sep 2017 11:09:21 +0000 (13:09 +0200)
- Fixes compilation error, when building under Windows (e.g. VS2015):
  ..\src\rrd_tune.c(410): error C2065: 'optind': undeclared identifier
- Use options.optind instead of optind
  optind is a member of the struct options

src/rrd_tune.c

index c718febf5a6a49447bf4b377829c895dca096a44..214b1fd6ce082404bc54650231f2dd2a49cb0cd4 100644 (file)
@@ -407,7 +407,7 @@ int rrd_tune(
             }
     }
 
-    optind = handle_modify(&rrd, in_filename, options.argc, options.argv, options.optind + 1, opt_newstep);
+    options.optind = handle_modify(&rrd, in_filename, options.argc, options.argv, options.optind + 1, opt_newstep);
     rc = 0;
 done:
     if (in_filename && rrdc_is_any_connected()) {