}
else {
#if !defined _MSC_VER && !defined __MINGW32__
- pos = (FLAC__uint64)(rand() % n);
+ pos = (FLAC__uint64)(random() % n);
#else
/* RAND_MAX is only 32767 in my MSVC */
- pos = (FLAC__uint64)((random()<<15|random()) % n);
+ pos = (FLAC__uint64)((rand()<<15|rand()) % n);
#endif
}
}
else {
#if !defined _MSC_VER && !defined __MINGW32__
- pos = (FLAC__uint64)(rand() % n);
+ pos = (FLAC__uint64)(random() % n);
#else
/* RAND_MAX is only 32767 in my MSVC */
- pos = (FLAC__uint64)((random()<<15|random()) % n);
+ pos = (FLAC__uint64)((rand()<<15|rand()) % n);
#endif
}
printf("seek failed, assuming it was past EOF... ");
else
printf("seek past end failed as expected... ");
+
/* hack to work around a deficiency in the seek API's behavior */
/* seeking past EOF sets the file decoder state to non-OK and there's no ..._flush() or ..._reset() call to reset it */
if(!OggFLAC__file_decoder_finish(decoder))