< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index  

Re: [reSIProcate-users] Assertion failed: RAND_MAX == ((1<<31)-1), file Random.cxx, line 302


Thanks Stuart.  I agree the assert is not right.  I will comment it out in SVN head.

Scott

On Wed, Oct 19, 2011 at 10:18 PM, Stuart Whelan <stuart@xxxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
Hello,

We are compiling on Solaris 5.10with gcc 4.3.3 for a 64bit application.

I have just updated from version 1.5 to 1.7 of resip.

We are not getting the assertion: Assertion failed: RAND_MAX == ((1<<31)-1), file Random.cxx, line 302.

Digging into our system headers, I find:

/usr/include/sio/stdlib_iso.h, line 3866: #define RAND_MAX        32767

This is obviously a problem for me...

Then I dug further into Random.cxx, and I see that it is actually calling random()..

RAND_MAX is not used, AFAIK, by random(). It is used by rand.

The man page for random() states 'All  the bits generated by random() are usable.'

So for the moment I have patched our resip to disable that assertion.

Cheers,
Stuart.

_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/