GOption: don't use "rand" in code example

rand() is a function defined in the libc, so our code example gives
warnings if you try to compile it.  Fix that.

https://bugzilla.gnome.org/show_bug.cgi?id=722025
This commit is contained in:
Ryan Lortie 2014-01-16 21:47:09 -05:00
parent d3c729bf0e
commit 9592d40613

View File

@ -99,7 +99,7 @@
* static gint max_size = 8; * static gint max_size = 8;
* static gboolean verbose = FALSE; * static gboolean verbose = FALSE;
* static gboolean beep = FALSE; * static gboolean beep = FALSE;
* static gboolean rand = FALSE; * static gboolean randomize = FALSE;
* *
* static GOptionEntry entries[] = * static GOptionEntry entries[] =
* { * {
@ -107,7 +107,7 @@
* { "max-size", 'm', 0, G_OPTION_ARG_INT, &max_size, "Test up to 2^M items", "M" }, * { "max-size", 'm', 0, G_OPTION_ARG_INT, &max_size, "Test up to 2^M items", "M" },
* { "verbose", 'v', 0, G_OPTION_ARG_NONE, &verbose, "Be verbose", NULL }, * { "verbose", 'v', 0, G_OPTION_ARG_NONE, &verbose, "Be verbose", NULL },
* { "beep", 'b', 0, G_OPTION_ARG_NONE, &beep, "Beep when done", NULL }, * { "beep", 'b', 0, G_OPTION_ARG_NONE, &beep, "Beep when done", NULL },
* { "rand", 0, 0, G_OPTION_ARG_NONE, &rand, "Randomize the data", NULL }, * { "rand", 0, 0, G_OPTION_ARG_NONE, &randomize, "Randomize the data", NULL },
* { NULL } * { NULL }
* }; * };
* *