Closed tbeu closed 9 years ago
@tbeu. I'm not 100% sure on how to integrate this. I have tried to do so here: https://github.com/akloeckner/Noise/commits/mutex. However, I get a compile error because "gconstructor.h" was not found. Would you mind checking this?
Thanks. That worked. I'm still not sure, if I have used the Mutex constructs correctly. However, I have opened a pull request #46 for this.
ModelicaRandom.c contains static variables ModelicaRandom_s, ModelicaRandom_p and ModelicaRandom_id but the access to these static variables is not thread-safe. In #1433 I fixed this for ModelicaInternal.c using macros
MUTEX_LOCK()
andMUTEX_UNLOCK()
on posix systems and Windows.This also needs to be applied to ModelicaRandom.c.