Jochen Voss [EMAIL PROTECTED] writes:
one very useful feature of gcc is, that it warns you when you
produce unterminated strings by using too long initialisers.
Unfortunately the warning only kicks in, if the initialiser is at
least two bytes longer than the string buffer.
This is
Jochen Voss [EMAIL PROTECTED] writes:
char string3[2] = 12;
char d[]=d;
char string4[2] = 123;
char e[]=e;
Here 'string3' and 'string4' are unterminated, as can be seen from the
program output at the end. But only the initialiser for 'string4'
gives a warning. It would
Package: gcc-4.1
Version: 4.1.1-16
Severity: normal
Hello,
one very useful feature of gcc is, that it warns you when you produce
unterminated strings by using too long initialisers. Unfortunately
the warning only kicks in, if the initialiser is at least two bytes
longer than the string buffer.
3 matches
Mail list logo