Minor fix to curve_fitting.c
Change-Id: Ib3669a5c4c73178b088dc1e80141f844f807b179
diff --git a/examples/curve_fitting.c b/examples/curve_fitting.c
index 1d1ec9b..3ea2ef1 100644
--- a/examples/curve_fitting.c
+++ b/examples/curve_fitting.c
@@ -155,6 +155,7 @@
double *parameter_pointers[] = { &m, &c };
int parameter_sizes[] = { 1, 1 };
+ int i;
ceres_problem_t* problem;
@@ -164,7 +165,7 @@
problem = ceres_create_problem();
/* Add all the residuals. */
- for (int i = 0; i < num_observations; ++i) {
+ for (i = 0; i < num_observations; ++i) {
ceres_problem_add_residual_block(
problem,
exponential_residual, /* Cost function */