aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2012-12-05 06:21:41 +0000
committerCarsten Haitzler <raster@rasterman.com>2012-12-05 06:21:41 +0000
commitb000cf12d69748e6b001a0a390a24d4b63e2106a (patch)
treeb72fd22313bcfa8a377ddf57f543b01cb0e527a3
parentde31494ade3e800d0385a1363c7ca651228cc167 (diff)
downloadenlightenment-b000cf12d69748e6b001a0a390a24d4b63e2106a.tar.gz
enlightenment-b000cf12d69748e6b001a0a390a24d4b63e2106a.tar.xz
enlightenment-b000cf12d69748e6b001a0a390a24d4b63e2106a.zip
only srand once.
SVN revision: 80209
-rw-r--r--src/bin/e_fm_op.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/bin/e_fm_op.c b/src/bin/e_fm_op.c
index 80af66a5a..bbec5f541 100644
--- a/src/bin/e_fm_op.c
+++ b/src/bin/e_fm_op.c
@@ -1764,7 +1764,13 @@ static void
_e_fm_op_random_char(char *buf, size_t len)
{
size_t i;
- srand((unsigned int)time(NULL));
+ static int sranded = 0;
+
+ if (!sranded)
+ {
+ srand((unsigned int)time(NULL));
+ sranded = 1;
+ }
for (i = 0; i < len; i++)
{