Fix for concurrent modification error that may occur in CCScheduler in a multithreaded game.