From: Dmitriy N. Borisov Date: Fri, 19 Dec 2014 08:13:55 +0000 (+0300) Subject: invalid type cast correction X-Git-Tag: v1.4.15^2~25^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c96d64e7e142d43db1864da17520d69268627aa3;p=thirdparty%2Ffreeswitch.git invalid type cast correction --- diff --git a/src/mod/endpoints/mod_sofia/sofia_reg.c b/src/mod/endpoints/mod_sofia/sofia_reg.c index b72070ba63..7e26470d73 100644 --- a/src/mod/endpoints/mod_sofia/sofia_reg.c +++ b/src/mod/endpoints/mod_sofia/sofia_reg.c @@ -857,7 +857,7 @@ long sofia_reg_uniform_distribution(int max) int result; int range = max + 1; - srand((unsigned) switch_thread_self() + switch_micro_time_now()); + srand((intptr_t) switch_thread_self() + switch_micro_time_now()); result = (int)((double)rand() / (((double)RAND_MAX + (double)1) / range)); switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG9, "Generated random %ld, max is %d\n", (long) result, max);