Fix ancient RAND_MAX compiler warning

This commit is contained in:
dak664 2010-12-13 16:52:02 +00:00
parent 3e293e6cfc
commit 9c66df6de1
3 changed files with 10 additions and 5 deletions

View file

@ -32,7 +32,7 @@
*
* This file is part of the Contiki operating system.
*
* $Id: rpl-timers.c,v 1.13 2010/11/03 15:41:23 adamdunkels Exp $
* $Id: rpl-timers.c,v 1.14 2010/12/13 16:52:02 dak664 Exp $
*/
/**
* \file
@ -93,7 +93,7 @@ new_dio_interval(rpl_dag_t *dag)
/* random number between I/2 and I */
time = time >> 1;
time += (time * random_rand()) / RANDOM_MAX;
time += (time * random_rand()) / RANDOM_RAND_MAX;
dag->dio_next_delay -= time;
dag->dio_send = 1;