]> git.smokeofanarchy.ru Git - space-station-14.git/commit
Clear MIDI masters properly to avoid replay freezes (#36809)
authorPieter-Jan Briers <pieterjan.briers+git@gmail.com>
Sat, 26 Apr 2025 06:42:16 +0000 (08:42 +0200)
committerVasilis The Pikachu <vasilis@pikachu.systems>
Mon, 28 Apr 2025 17:51:41 +0000 (19:51 +0200)
commitb629cbac3e6993164c6c8a6fe41d709f3a5ffd33
treeb0e39e0aa25ad8fcbc69569285d28e0a5ac55c41
parent0a394d4af5b3b5320a011ae2bbe0542f41fe22dc
Clear MIDI masters properly to avoid replay freezes (#36809)

While trying to play a replay I noticed that the replay would freeze
when seeking in some cases. After some debugging, I discovered that two
MIDI renderers had each other as master, which caused an infinite loop
processing MIDI events.

I'm not entirely sure of the sequence of events that leads to this
during replay playback, but I did notice that MIDI render masters are
never set to null. This is in the best case just a memory leak, in the
worst case probably the source of the bug, so... I fixed that.
Content.Client/Instruments/InstrumentSystem.cs