mirror of
https://github.com/claunia/flac.git
synced 2025-12-16 18:54:26 +00:00
C89 fix (SF#1613348: http://sourceforge.net/tracker/index.php?func=detail&aid=1613348&group_id=13478&atid=313478)
This commit is contained in:
@@ -730,13 +730,15 @@ int main(int argc, char *argv[])
|
||||
is_big_endian_host = (*((FLAC__byte*)(&test)))? false : true;
|
||||
|
||||
#if !defined _MSC_VER && !defined __MINGW32__
|
||||
struct timeval tv;
|
||||
{
|
||||
struct timeval tv;
|
||||
|
||||
if(gettimeofday(&tv, 0) < 0) {
|
||||
fprintf(stderr, "WARNING: couldn't seed RNG with time\n");
|
||||
tv.tv_usec = 4321;
|
||||
if(gettimeofday(&tv, 0) < 0) {
|
||||
fprintf(stderr, "WARNING: couldn't seed RNG with time\n");
|
||||
tv.tv_usec = 4321;
|
||||
}
|
||||
srandom(tv.tv_usec);
|
||||
}
|
||||
srandom(tv.tv_usec);
|
||||
#else
|
||||
srand(time(0));
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user