/*
- * "$Id: rasterbench.c 6649 2007-07-11 21:46:42Z mike $"
+ * "$Id: rasterbench.c 7376 2008-03-19 21:07:45Z mike $"
*
* Raster benchmark program for the Common UNIX Printing System (CUPS).
*
* Include necessary headers...
*/
+#include <config.h>
#include <cups/raster.h>
#include <stdlib.h>
#include <sys/time.h>
* text with some whitespace.
*/
- srand(time(NULL));
+ CUPS_SRAND(time(NULL));
memset(data, 0, sizeof(data));
for (y = 0; y < 28; y ++)
{
- for (x = rand() & 127, count = (rand() & 15) + 1;
+ for (x = CUPS_RAND() & 127, count = (CUPS_RAND() & 15) + 1;
x < sizeof(data[0]);
x ++, count --)
{
if (count <= 0)
{
- x += (rand() & 15) + 1;
- count = (rand() & 15) + 1;
+ x += (CUPS_RAND() & 15) + 1;
+ count = (CUPS_RAND() & 15) + 1;
if (x >= sizeof(data[0]))
break;
}
- data[y][x] = rand();
+ data[y][x] = CUPS_RAND();
}
}
/*
- * End of "$Id: rasterbench.c 6649 2007-07-11 21:46:42Z mike $".
+ * End of "$Id: rasterbench.c 7376 2008-03-19 21:07:45Z mike $".
*/