]> pd.if.org Git - pdclib/blobdiff - functions/stdlib/rand.c
PDCLib includes with quotes, not <>.
[pdclib] / functions / stdlib / rand.c
index b8163a381c145ba6779d9ae20b81a23f6579c87a..1e8f3cd789b2542ba0e7ab78c969cb412ff325c7 100644 (file)
@@ -1,7 +1,3 @@
-/* $Id$ */
-
-/* Release $Name$ */
-
 /* rand( void )
 
    This file is part of the Public Domain C Library (PDCLib).
 int rand( void )
 {
     _PDCLIB_seed = _PDCLIB_seed * 1103515245 + 12345;
-    return (unsigned int) ( _PDCLIB_seed / 65536 ) % 32768;
+    return (int)( _PDCLIB_seed / 65536 ) % 32768;
 }
 
 #endif
 
 #ifdef TEST
-#include <_PDCLIB_test.h>
+#include "_PDCLIB_test.h"
 
-int main()
+int main( void )
 {
     int rnd1, rnd2;
-    BEGIN_TESTS;
     TESTCASE( ( rnd1 = rand() ) < RAND_MAX );
     TESTCASE( ( rnd2 = rand() ) < RAND_MAX );
     srand( 1 );