izzyreal / mpc

mpc2000xl emulator static library
GNU General Public License v3.0
73 stars 8 forks source link

Loading an ALL file is not thread-safe #165

Closed izzyreal closed 1 year ago

izzyreal commented 1 year ago

Results in crashes on iOS, maybe on other platforms too. Related to FrameSeq continuously calling Sequencer::getTempo, which depends on Sequencer::sequences, which gets purged and reinitialized when loading an ALL file.

Basically there has to be a thread-safe way to initialize a Sequence. We could use a std::mutex or std::atomic<bool>.

izzyreal commented 1 year ago

Resolved in 7647b7159262d6a3facec4c3f05149b2dcc6a854