Skip to content

Commit

Permalink
[compile] fix non-c99 regression in for() loop (#538)
Browse files Browse the repository at this point in the history
Reviewed-by: Benn Snyder <benn.snyder@gmail.com>
  • Loading branch information
smokhov authored and piedar committed Dec 12, 2017
1 parent 6749db9 commit 34f7412
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fakenect/fakenect.c
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,8 @@ int freenect_init(freenect_context **ctx, freenect_usb_context *usb_ctx)
if (var) {
int len = strlen(var);
char tmp[len + 1];
for (int i = 0; i < len; i++)
int i;
for (i = 0; i < len; i++)
tmp[i] = tolower(var[i]);
tmp[len] = '\0';
if (strcmp(tmp, "0") == 0 ||
Expand Down

0 comments on commit 34f7412

Please sign in to comment.