Skip to content

Removed uneeded decleration within for#5254

Closed
Mipsters wants to merge 3 commits intocurl:masterfrom
Mipsters:master
Closed

Removed uneeded decleration within for#5254
Mipsters wants to merge 3 commits intocurl:masterfrom
Mipsters:master

Conversation

@Mipsters
Copy link
Copy Markdown
Contributor

fixed error: 'for' loop initial declaration used outside C99 mode
by declaring i in the beginning of the block instead of inside the for loop

gcc version 3.3.5 (Debian 1:3.3.5-13)

after fix and successful compilation, make test results:
https://pastebin.com/znEufH5H

fixed error: 'for' loop initial declaration used outside C99 mode
by declaring i in the beginning of the block instead of inside the for loop

gcc version 3.3.5 (Debian 1:3.3.5-13)

after fix and successful compilation, `make test` results:
https://pastebin.com/znEufH5H
@danielgustafsson
Copy link
Copy Markdown
Member

There is another one in docs/examples/crawler.c which I think we should change too to keep us C89 across the tree. Care to include that one too in this patch?

@Mipsters
Copy link
Copy Markdown
Contributor Author

Done!
maybe the ci cd should include an old compiler test?
I noticed this because I work with a very old compiler, and it's best to catch these things early!
just a suggestion of course :)

@danielgustafsson
Copy link
Copy Markdown
Member

Thanks, looks good! There is a copyrightyear warning but don't worry about that one, I'll take care of that when pushing to master.

@danielgustafsson
Copy link
Copy Markdown
Member

Pushed with a tweak to the copyright year and some mild copyediting of the commit message. Thanks for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants