Hi,
The nbd configure.ac contains:
AC_PROG_CC_C99
because I use a number of C99 constructs in the code. When, however, I
run configure like so:
./configure CFLAGS='-g -O0 -Wall -Werror'
because I want to clean up the code a bit, I get an error message at
compile time:
nbdsrv.c: In function 'getmaskbyte':
nbdsrv.c:116:2: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
for(int i = 7; i + masklen > 7; i--) {
^
which is surprising, since I asked for C99 mode. If I specify CFLAGS so
it also contains '-std=gnu99', then everything compiles cleanly (apart
from the bits that are caused by the -Wall -Werror, that is).