Skip to content

Commit 2902876

Browse files
authored
Merge pull request #1938 from grumpycoders/psyqo-callbacks-delay
Delay re-queued callbacks a bit.
2 parents 285c320 + abc5270 commit 2902876

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/mips/psyqo/src/kernel.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,8 @@ void psyqo::Kernel::Internal::pumpCallbacks() {
409409
if (s_flag == 0) return;
410410
fastEnterCriticalSection();
411411
s_flag = 0;
412-
while (!s_callbacks.empty()) {
412+
auto count = s_callbacks.size();
413+
for (size_t i = 0; i < count; i++) {
413414
auto& l = s_callbacks.front();
414415
fastLeaveCriticalSection();
415416
l();

0 commit comments

Comments
 (0)