summaryrefslogtreecommitdiff
path: root/res/res_musiconhold.c
diff options
context:
space:
mode:
Diffstat (limited to 'res/res_musiconhold.c')
-rw-r--r--res/res_musiconhold.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/res/res_musiconhold.c b/res/res_musiconhold.c
index 4c0f93213..314c0762a 100644
--- a/res/res_musiconhold.c
+++ b/res/res_musiconhold.c
@@ -208,7 +208,7 @@ static int ast_moh_files_next(struct ast_channel *chan)
}
if (ast_test_flag(state->class, MOH_RANDOMIZE))
- state->pos = rand();
+ state->pos = ast_random();
/* check to see if this file's format can be opened */
if (ast_fileexists(state->class->filearray[state->pos], NULL, NULL) != -1)