Re: question on using random in C on FC4 (perhaps slightly OT)

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

 



Andy Green wrote:

> gcc -c -O3 -Wall -pedantic test.c
> 
> works fine here with no errors or warnings.

Gah missed out the -std=c99 !  Same error here then.

$ gcc -c -O3 -std=c99 -Wall -pedantic test.c
test.c: In function ‘main’:
test.c:5: warning: implicit declaration of function ‘random’
test.c:5: warning: format ‘%ld’ expects type ‘long int’, but argument 2
has type ‘int’

-Andy

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux