[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: odd compiler behaviour?

also sprach Bruynooghe Floris <fb102@soton.ac.uk> [2003.03.14.1700 +0100]:
>   char* record;
>   int record_size = 10;
>   record = (char*) malloc (record_size);
>   int letter = 'a';
>   int i;

the declaration of i has to go before the 'record = ' assignment.
that's a limitation of C, and unless you put gcc into C99 mode, it
will bitch. anyway, i am not sure this will solve it, but try it...

Please do not CC me when replying to lists; I read them!
 .''`.     martin f. krafft <madduck@debian.org>
: :'  :    proud Debian developer, admin, and user
`. `'`
  `-  Debian - when you have better things to do than fixing a system
Keyserver problems? http://keyserver.kjsl.com/~jharris/keyserver.html
Get my key here: http://people.debian.org/~madduck/gpg/330c4a75.asc

Attachment: pgpgxL2MuEJPm.pgp
Description: PGP signature

Reply to: