LancePutnam / Gamma

Generic (Sound) Synthesis Library
Other
458 stars 54 forks source link

Android pthread_cancel() #46

Closed Achder closed 7 years ago

Achder commented 7 years ago

Can't compile the library, because Android doesn't support pthread_cancel(). Is there a workaround for this?

LancePutnam commented 7 years ago

Not that I know of. Thread cancellation seems to be considered bad practice these days (e.g. no support under std::thread) since it can lead to resource leaks. See http://stackoverflow.com/questions/13893060/i-want-to-kill-a-stdthread-using-its-thread-object

For this reason and the fact that Thread::cancel is not used internally by Gamma, I have removed it.