I'm trying to use the function drand48, but when I call it, it causes a segmentation fault.
I do put in the top of my source file:
Code: Select all
#define _XOPEN_SOURCE
#include <stdlib.h>
Code: Select all
srand48(long_int_var);
Calling the function rand (after srand) is also causing segmentation fault.
I'm starting to think it's a problem with the Raspberry Pi, or with my version of the C standard lib.