Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to compile on CentOS 7 with GCC 4.8.5 #3

Open
yantarou opened this issue Mar 14, 2021 · 0 comments · May be fixed by #4
Open

Fails to compile on CentOS 7 with GCC 4.8.5 #3

yantarou opened this issue Mar 14, 2021 · 0 comments · May be fixed by #4

Comments

@yantarou
Copy link

On CentOS 7, gcc fails with the following error:

$ make
gcc -o dnsflood -g -DDEBUG dnsflood.c
dnsflood.c: In function ‘gen_random’:
dnsflood.c:230:5: error: ‘for’ loop initial declarations are only allowed in C99 mode
     for (int i = 0; i < len; ++i) {
     ^
dnsflood.c:230:5: note: use option -std=c99 or -std=gnu99 to compile your code
make: *** [dnsflood] Error 1
$ cat /etc/redhat-release 
CentOS Linux release 7.8.2003 (Core)
$ gcc --version
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)
@yantarou yantarou linked a pull request Mar 14, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant